tsc_LibraryFeature

The tsc_LibraryFeature class represents a single feature from a Feature Library and any attributes it may contain.  A Feature Library consists of a list of these objects.

The only way to obtain a tsc_LibraryFeature is from a tsc_FeatureLibrary object.

A library feature contains a list of attributes.  With normal General Survey usage, when a feature is chosen for a database entity such as a point, the user will be asked to enter a value for each of the attributes contained in the feature, except for those which are read-only.  A plugin may make its own rules about input of attributes, and perhaps supply some values itself for storing with the point.  

Public members

tsc_LibraryFeature ();

Construct an empty feature, to which another which can be assigned.

tsc_LibraryFeature (const tsc_LibraryFeature&);

The copy constructor creates a reference to the same feature object.

tsc_LibraryFeature& operator= (const tsc_LibraryFeature&);

Assignment makes a reference to the same feature object.

tsc_String Name () const;

Returns the name of the feature. In Trimble office software and in the FXL file format, this field is known as the Code.

tsc_String DescriptiveName () const;

Returns the descriptive name of the feature. In Trimble office software and in the FXL file format, this field is known as the Name.

tsc_LibraryAttribute operator[] (int index) const;

Returns the attribute at the given zero-based index. The operation fails if the index is not valid.

tsc_LibraryAttribute operator[] (const char* attributeName) const;

Returns the attribute of the given name.  If no such attribute exists, the returned object will return false from its IsNull() method.

tsc_LibraryAttribute AtIndex (int index) const;

Returns the attribute at the given zero-based index. The operation fails if the index is not valid.

int IndexOf (const char* attributeName) const;

Returns the index of the attribute with the given name, or NULL if there is no such attribute.

bool Contains (const char* attributeName) const;

Returns true if the named attribute exists.

int AttributeCount () const;

Returns the number of attributes in this feature.