|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.odi.DatabaseSegmentEnumeration
The DatabaseSegmentEnumeration class defines the operations for enumerating the segments in a database. A DatabaseSegmentEnumeration object is a list of the segments in a database. An application can create a DatabaseSegmentEnumeration object with a call to Database.getSegments(). The DatabaseSegmentEnumeration object that it creates is valid only until the end of the transaction.
If you create a DatabaseSegmentEnumeration object and then create a new segment, PSE/PSE Pro might or might not include the new segment in the enumeration. Consequently, you should create a new enumeration when it matters whether or not the new segment is included in the enumeration.
After an application creates a DatabaseSegmentEnumeration, a segment in the enumeration might get destroyed. In this situation, you might still obtain the destroyed segment, but if you try to do something with it PSE/PSE Pro throws SegmentNotFoundException.
When you are using PSE or PSE Pro, a database can have only one segment.
Method Summary | |
abstract boolean |
hasMoreElements()
Determines whether or not there are any more segments in the enumeration. |
abstract Object |
nextElement()
Obtains the next database segment as an Object. |
abstract Segment |
nextSegment()
Obtains the next database segment as a Segment. |
Method Detail |
public abstract boolean hasMoreElements()
hasMoreElements
in interface Enumeration
NoTransactionInProgressException
- If a transaction is not in
progress.
ObjectStoreException
- If the session implied by the
enumeration has been terminated or if the current thread is associated
with a session other than the session implied by the enumeration.
StaleEnumeratorException
- If the information for this
enumeration has become stale and unusable. This currently occurs at the
end of the transaction in which the enumeration was created.public abstract Object nextElement()
nextElement
in interface Enumeration
NoSuchElementException
- If there are no more segments.
NoTransactionInProgressException
- If a transaction is not in
progress.
ObjectStoreException
- If the session implied by the
enumeration has been terminated or if the current thread is associated
with a session other than the session implied by the enumeration.
StaleEnumeratorException
- If the information for this
enumeration has become stale and unusable. This currently occurs at the
end of the transaction in which the enumeration was created.public abstract Segment nextSegment()
NoSuchElementException
- If there are no more segments.
NoTransactionInProgressException
- If a transaction is not in
progress.
ObjectStoreException
- If the session implied by the
enumeration has been terminated or if the current thread is associated
with a session other than the session implied by the enumeration.
StaleEnumeratorException
- If the information for this
enumeration has become stale and unusable. This currently occurs at the
end of the transaction in which the enumeration was created.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |