public class ChronicleImpl extends DBObjectImpl implements Chronicle
Chronicle.| Modifier and Type | Class and Description |
|---|---|
static class |
ChronicleImpl.RawData
RawData encapsulates the low level members of a chronicle.
|
| Modifier | Constructor and Description |
|---|---|
|
ChronicleImpl(ChronicleImpl.RawData rawData)
Construct a
Chronicle. |
protected |
ChronicleImpl(String name,
String description,
Chronicle parent,
Schema schema,
Surrogate surrogate)
Construct a
Chronicle. |
|
ChronicleImpl(Surrogate surrogate)
Construct a
Chronicle. |
| Modifier and Type | Method and Description |
|---|---|
UpdatableChronicle |
edit()
Return an
UpdatableChronicle corresponding to this chronicle. |
Chronicle |
findChronicle(String fullName,
boolean mustExist)
Find the chronicle with the the given full name.
|
Attribute<?> |
getAttribute(String attrName,
boolean mustExist)
Return the attribute with the given name.
|
Collection<Attribute<?>> |
getAttributes()
Return all the chronicle's attributes.
|
Chronicle |
getChronicle(String simpleName,
boolean mustExist)
Return the direct child of this chronicle with the given simple name.
|
Chronicle |
getCollection()
Return the chronicle to which this chronicle belongs.
|
String |
getDescription(boolean full)
Return the description of the chronicle.
|
List<String> |
getDescriptions()
Return the list of all descriptions along the chronicle chain.
|
Collection<Chronicle> |
getMembers()
Return the direct members of this chronicle seen as a collection.
|
String |
getName(boolean full)
Return the name of the chronicle.
|
List<String> |
getNames()
Return the list of all names along the chronicle chain.
|
Schema |
getSchema(boolean effective)
Return the chronicle's schema.
|
Collection<Series<?>> |
getSeries()
Return all existing series in this chronicle.
|
<T> Series<T> |
getSeries(String name)
Return the series with the given simple name.
|
<T> Series<T>[] |
getSeries(String[] names,
Class<T> type,
boolean mustBeDefined)
Return an array of series corresponding to the names requested.
|
boolean |
isMemberOf(Chronicle collection)
Return true if this chronicle is member of the collection.
|
boolean |
isTopChronicle()
Return true if this is the top chronicle.
|
String |
toString() |
protected void |
update()
Force refresh of state on next access.
|
equals, getDatabase, getId, getSurrogate, hashCode, inConstruction, isValidclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetDatabase, getId, getSurrogate, inConstruction, isValidpublic ChronicleImpl(Surrogate surrogate)
Chronicle.surrogate - a chronicle surrogateprotected ChronicleImpl(String name, String description, Chronicle parent, Schema schema, Surrogate surrogate)
Chronicle.name - a stringdescription - a stringparent - a chronicle or nullschema - a schema or nullsurrogate - a surrogatepublic ChronicleImpl(ChronicleImpl.RawData rawData) throws T2DBException
Chronicle.rawData - a raw data objectT2DBExceptionpublic Chronicle getChronicle(String simpleName, boolean mustExist) throws T2DBException
ChroniclemustExist parameter determines behavior when nothing is
found: exception or null result.getChronicle in interface ChroniclesimpleName - a simple namemustExist - if true throw an exception instead of returning nullT2DBExceptionpublic Chronicle findChronicle(String fullName, boolean mustExist) throws T2DBException
ChroniclemustExist
is false, a non-existing chronicle is tolerated when it is at the end of
the chain of simple names.findChronicle in interface ChroniclefullName - the full name of the chroniclemustExist - if true throw an exception instead of returning nullT2DBExceptionpublic boolean isTopChronicle()
ChronicleisTopChronicle in interface Chroniclepublic UpdatableChronicle edit()
ChronicleUpdatableChronicle corresponding to this chronicle.
Successfully getting an Updatable object does not imply
that updates can be successfully applied.protected void update()
public Chronicle getCollection() throws T2DBException
ChroniclegetCollection in interface ChronicleT2DBExceptionpublic Collection<Chronicle> getMembers() throws T2DBException
ChroniclegetMembers in interface ChronicleT2DBExceptionpublic Schema getSchema(boolean effective) throws T2DBException
Chronicleeffective parameter is true, the schema
returned is the first non-null schema encountered along the chronicle chain.
Also in this case the result can be null.getSchema in interface Chronicleeffective - if true return the first non-null schema along the chronicle chainT2DBExceptionpublic String getName(boolean full) throws T2DBException
ChroniclegetName in interface Chroniclefull - if true return the full name, else the simple nameT2DBExceptionpublic List<String> getNames() throws T2DBException
ChroniclegetNames in interface ChronicleT2DBExceptionpublic String getDescription(boolean full) throws T2DBException
ChroniclegetDescription in interface Chroniclefull - if true return the full description, else the simple
descriptionT2DBExceptionpublic List<String> getDescriptions() throws T2DBException
ChroniclegetDescriptions in interface ChronicleT2DBExceptionpublic Attribute<?> getAttribute(String attrName, boolean mustExist) throws T2DBException
ChroniclegetAttribute in interface ChronicleattrName - a stringmustExist - if true throw an exception instead of returning nullT2DBExceptionpublic <T> Series<T> getSeries(String name) throws T2DBException
ChroniclegetSeries in interface ChronicleT - the data type of the underlying time seriesname - the simple name if the seriesT2DBExceptionpublic <T> Series<T>[] getSeries(String[] names, Class<T> type, boolean mustBeDefined) throws T2DBException
ChroniclemustBeDefined is false (in which case the
series is treated like a missing series). If the value type does not
correspond to the type requested an exception is thrown. If a series is
missing (there are no values), a null is returned in its place.getSeries in interface ChronicleT - the data type of the underlying time seriesnames - the names of the series requestedtype - the expected type or null to bypass enforcing a typemustBeDefined - if true throw an exception when a name is undefinedT2DBExceptionpublic Collection<Attribute<?>> getAttributes() throws T2DBException
ChroniclegetAttributes in interface ChronicleT2DBExceptionpublic Collection<Series<?>> getSeries() throws T2DBException
ChroniclegetSeries in interface ChronicleT2DBExceptionpublic boolean isMemberOf(Chronicle collection) throws T2DBException
ChronicleisMemberOf in interface Chroniclecollection - a chronicleT2DBExceptionCopyright © 2017. All rights reserved.