java.lang.Object | |
↳ | com.microstrategy.web.app.utils.FileContentsObjectList |
Title: FileContentsObjectList class
Description: This class has been created with the purpose of handling the objects that
get saved to files. Each object is represented by a
FileContentsObjectWrapper
instance and this class represents
a collection of these instances.
Copyright: Copyright (c) 2001
Company: MicroStrategy, Inc.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
FileContentsObjectList()
Class Constructor.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
void |
add(FileContentsObjectWrapper newObject)
Adds a new element to this instance.
| ||||||||||
FileContentsObjectWrapper |
get(int index)
Returns the
FileContentsObjectWrapper instance at the indicated index position. | ||||||||||
FileContentsObjectList |
get(String key)
Analyzes all the list searching for objects with the specified key and returns a new
collection with the elements found.
| ||||||||||
boolean |
hasNext()
Verifies if the list has another element after the one that it's currently being pointed
at.
| ||||||||||
int |
indexOf(FileContentsObjectWrapper obj)
Searches for the requested object and returns its position on this collection.
| ||||||||||
FileContentsObjectWrapper |
next()
Returns the next
FileContentsObjectWrapper element available on the
collection. | ||||||||||
boolean |
remove(FileContentsObjectWrapper oldObject)
Searches for the object sent as parameter and removes its first instance from this
collection.
| ||||||||||
void |
remove(int index)
Removes the indicated element from this collection instance
| ||||||||||
void |
remove()
Removes the collection element that it's currently pointed at.
| ||||||||||
void |
resetList()
Creates a pointer to the list contents and sets it to the first element on the list.
| ||||||||||
void |
set(int index, FileContentsObjectWrapper obj)
Modifies the indicated element of this collection with the object sent as parameter.
| ||||||||||
int |
size()
Returns the number of elements on this list.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Class Constructor.
Adds a new element to this instance.
newObject | Instance of FileContentsObjectWrapper to add at the end
of this collection.
|
---|
Returns the FileContentsObjectWrapper
instance at the indicated index position.
index | Value of the index from where to return the element instance from this collection |
---|
FileContentsObjectWrapper
instance corresponding to the requested indexWebAppException | if an error ocurrs while trying to get the requested element |
---|
Analyzes all the list searching for objects with the specified key and returns a new collection with the elements found.
key | String value of the key to search for |
---|
FileContentsObjectList
> collection with the elements found with the
specified key.
Verifies if the list has another element after the one that it's currently being pointed at.
True
if there's another element on the list, otherwise it returns
False
Searches for the requested object and returns its position on this collection. The object to search needs to be one of the objects of this list.
obj | The FileContentsObjectWrapper instance to search on the
collection |
---|
Returns the next FileContentsObjectWrapper
element available on the
collection. If no pointer has been defined yet, it creates it.
FileContentsObjectWrapper
instance pointing to the next element in the list
Searches for the object sent as parameter and removes its first instance from this collection. The object to delete needs to be one of the actual elements of this list.
oldObject | FileContentsObjectWrapper list instance to be searched for
and removed from the collection. |
---|
True
if there was an element being removed, otherwise returns
False
.
Removes the indicated element from this collection instance
index | int index value of the element to be removed from the list. |
---|
WebAppException | if an error ocurrs while removing the requested element |
---|
Removes the collection element that it's currently pointed at.
Creates a pointer to the list contents and sets it to the first element on the list.
Modifies the indicated element of this collection with the object sent as parameter. The object to search and replace needs to be one of the objects of this list.
index | Index indicating the position of the element to be modified. |
---|---|
obj | FileContentsObjectWrapper instance to replace the old element. |
WebAppException | if an error ocurrs while setting the object |
---|
Returns the number of elements on this list.