Lucene++ - a full-featured, c++ search engine
API Documentation
The start and end character offset of a Token. More...
#include <PayloadAttribute.h>
Inheritance diagram for Lucene::PayloadAttribute:Public Member Functions | |
| PayloadAttribute () | |
| Initialize this attribute with no payload. More... | |
| PayloadAttribute (const PayloadPtr &payload) | |
| Initialize this attribute with the given payload. More... | |
| virtual | ~PayloadAttribute () |
| virtual String | getClassName () |
| boost::shared_ptr< PayloadAttribute > | shared_from_this () |
| virtual String | toString () |
| Returns a string representation of the object. More... | |
| virtual PayloadPtr | getPayload () |
| Returns this Token's payload. More... | |
| virtual void | setPayload (const PayloadPtr &payload) |
| Sets this Token's payload. More... | |
| virtual void | clear () |
| Clears the values in this Attribute and resets it to its default value. If this implementation implements more than one Attribute interface it clears all. More... | |
| virtual LuceneObjectPtr | clone (const LuceneObjectPtr &other=LuceneObjectPtr()) |
| Shallow clone. Subclasses must override this if they need to clone any members deeply. More... | |
| virtual bool | equals (const LuceneObjectPtr &other) |
All values used for computation of hashCode() should be checked here for equality. More... | |
| virtual int32_t | hashCode () |
| Subclasses must implement this method and should compute a hashCode similar to this: More... | |
| virtual void | copyTo (const AttributePtr &target) |
| Copies the values from this Attribute into the passed-in target attribute. The target implementation must support all the Attributes this implementation supports. More... | |
Public Member Functions inherited from Lucene::Attribute | |
| virtual | ~Attribute () |
| virtual String | getClassName () |
| boost::shared_ptr< Attribute > | shared_from_this () |
| virtual void | clear ()=0 |
| Clears the values in this Attribute and resets it to its default value. If this implementation implements more than one Attribute interface it clears all. More... | |
| virtual int32_t | hashCode ()=0 |
| Subclasses must implement this method and should compute a hashCode similar to this: More... | |
| virtual bool | equals (const LuceneObjectPtr &other)=0 |
All values used for computation of hashCode() should be checked here for equality. More... | |
| virtual void | copyTo (const AttributePtr &target)=0 |
| Copies the values from this Attribute into the passed-in target attribute. The target implementation must support all the Attributes this implementation supports. More... | |
| virtual LuceneObjectPtr | clone (const LuceneObjectPtr &other=LuceneObjectPtr())=0 |
| Shallow clone. Subclasses must override this if they need to clone any members deeply. More... | |
Public Member Functions inherited from Lucene::LuceneObject | |
| virtual | ~LuceneObject () |
| virtual void | initialize () |
| Called directly after instantiation to create objects that depend on this object being fully constructed. More... | |
| virtual LuceneObjectPtr | clone (const LuceneObjectPtr &other=LuceneObjectPtr()) |
| Return clone of this object. More... | |
| virtual int32_t | hashCode () |
| Return hash code for this object. More... | |
| virtual bool | equals (const LuceneObjectPtr &other) |
| Return whether two objects are equal. More... | |
| virtual int32_t | compareTo (const LuceneObjectPtr &other) |
| Compare two objects. More... | |
| virtual String | toString () |
| Returns a string representation of the object. More... | |
Public Member Functions inherited from Lucene::LuceneSync | |
| virtual | ~LuceneSync () |
| virtual SynchronizePtr | getSync () |
| Return this object synchronize lock. More... | |
| virtual LuceneSignalPtr | getSignal () |
| Return this object signal. More... | |
| virtual void | lock (int32_t timeout=0) |
| Lock this object using an optional timeout. More... | |
| virtual void | unlock () |
| Unlock this object. More... | |
| virtual bool | holdsLock () |
| Returns true if this object is currently locked by current thread. More... | |
| virtual void | wait (int32_t timeout=0) |
| Wait for signal using an optional timeout. More... | |
| virtual void | notifyAll () |
| Notify all threads waiting for signal. More... | |
Static Public Member Functions | |
| static String | _getClassName () |
Static Public Member Functions inherited from Lucene::Attribute | |
| static String | _getClassName () |
Protected Attributes | |
| PayloadPtr | payload |
Protected Attributes inherited from Lucene::LuceneSync | |
| SynchronizePtr | objectLock |
| LuceneSignalPtr | objectSignal |
Additional Inherited Members | |
Protected Member Functions inherited from Lucene::LuceneObject | |
| LuceneObject () | |
The start and end character offset of a Token.
| Lucene::PayloadAttribute::PayloadAttribute | ( | ) |
Initialize this attribute with no payload.
| Lucene::PayloadAttribute::PayloadAttribute | ( | const PayloadPtr & | payload | ) |
Initialize this attribute with the given payload.
|
virtual |
|
inlinestatic |
|
virtual |
Clears the values in this Attribute and resets it to its default value. If this implementation implements more than one Attribute interface it clears all.
Implements Lucene::Attribute.
|
virtual |
Shallow clone. Subclasses must override this if they need to clone any members deeply.
| base | clone reference - null when called initially, then set in top virtual override. |
Implements Lucene::Attribute.
|
virtual |
Copies the values from this Attribute into the passed-in target attribute. The target implementation must support all the Attributes this implementation supports.
Implements Lucene::Attribute.
|
virtual |
All values used for computation of hashCode() should be checked here for equality.
see also LuceneObject#equals(Object)
Implements Lucene::Attribute.
|
inlinevirtual |
Reimplemented from Lucene::Attribute.
|
virtual |
Returns this Token's payload.
|
virtual |
Subclasses must implement this method and should compute a hashCode similar to this:
int32_t hashCode() { int32_t code = startOffset; code = code * 31 + endOffset; return code; }
see also equals(Object)
Implements Lucene::Attribute.
|
virtual |
Sets this Token's payload.
|
inline |
|
virtual |
Returns a string representation of the object.
Reimplemented from Lucene::LuceneObject.
|
protected |