#include <classad.h>
Inheritance diagram for ClassAd:


STL-like Iterators | |
| typedef AttrList::iterator | iterator |
| Define an iterator we can use on a ClassAd. | |
| typedef AttrList::const_iterator | const_iterator |
| Define a constatnt iterator we can use on a ClassAd. | |
| iterator | begin () |
| Returns an iterator pointing to the beginning of the attribute/value pairs in the ClassAd. | |
| const_iterator | begin () const |
| Returns a constant iterator pointing to the beginning of the attribute/value pairs in the ClassAd. | |
| iterator | end () |
| Returns aniterator pointing past the end of the attribute/value pairs in the ClassAd. | |
| const_iterator | end () const |
| Returns a constant iterator pointing past the end of the attribute/value pairs in the ClassAd. | |
| iterator | find (std::string const &attrName) |
| Return an interator pointing to the attribute with a particular name. | |
| const_iterator | find (std::string const &attrName) const |
| Return a constant interator pointing to the attribute with a particular name. | |
| int | size (void) const |
| Return the number of attributes at the root level of this ClassAd. | |
Dirty Tracking | |
| typedef DirtyAttrList::iterator | dirtyIterator |
| void | EnableDirtyTracking (void) |
| Turn on dirty tracking for this ClassAd. | |
| void | DisableDirtyTracking (void) |
| Turn off ditry tracking for this ClassAd. | |
| void | ClearAllDirtyFlags (void) |
| Mark all attributes in the ClassAd as not dirty. | |
| void | MarkAttributeDirty (const std::string &name) |
| Mark a particular attribute as dirty. | |
| void | MarkAttributeClean (const std::string &name) |
| Mark a particular attribute as not dirty. | |
| bool | IsAttributeDirty (const std::string &name) |
| Return true if an attribute is dirty. | |
| dirtyIterator | dirtyBegin () |
| Return an interator to the first dirty attribute so all dirty attributes can be iterated through. | |
| dirtyIterator | dirtyEnd () |
| Return an iterator past the last dirty attribute. | |
Constructors/Destructor | |
| ClassAd () | |
| Default constructor. | |
| ClassAd (const ClassAd &ad) | |
| ad The ClassAd to copy | |
| ~ClassAd () | |
| Destructor. | |
Insertion Methods | |
| bool | Insert (const std::string &attrName, ExprTree *expr) |
| Inserts an attribute into the ClassAd. | |
| bool | DeepInsert (ExprTree *scopeExpr, const std::string &attrName, ExprTree *expr) |
| Inserts an attribute into a nested classAd. | |
| bool | InsertAttr (const std::string &attrName, int value, Value::NumberFactor f=Value::NO_FACTOR) |
| Inserts an attribute into the ClassAd. | |
| bool | DeepInsertAttr (ExprTree *scopeExpr, const std::string &attrName, int value, Value::NumberFactor f=Value::NO_FACTOR) |
| Inserts an attribute into a nested classad. | |
| bool | InsertAttr (const std::string &attrName, double value, Value::NumberFactor f=Value::NO_FACTOR) |
| Inserts an attribute into the ClassAd. | |
| bool | DeepInsertAttr (ExprTree *scopeExpr, const std::string &attrName, double value, Value::NumberFactor f=Value::NO_FACTOR) |
| Inserts an attribute into a nested classad. | |
| bool | InsertAttr (const std::string &attrName, bool value) |
| Inserts an attribute into the ClassAd. | |
| bool | DeepInsertAttr (ExprTree *scopeExpr, const std::string &attrName, bool value) |
| Inserts an attribute into a nested classad. | |
| bool | InsertAttr (const std::string &attrName, const char *value) |
| Inserts an attribute into the ClassAd. | |
| bool | DeepInsertAttr (ExprTree *scopeExpr, const std::string &attrName, const char *value) |
| Inserts an attribute into a nested classad. | |
| bool | InsertAttr (const std::string &attrName, const std::string &value) |
| Inserts an attribute into the ClassAd. | |
| bool | DeepInsertAttr (ExprTree *scopeExpr, const std::string &attrName, const std::string &value) |
| Inserts an attribute into a nested classad. | |
Lookup Methods | |
| ExprTree * | Lookup (const std::string &attrName) const |
| Finds the expression bound to an attribute name. | |
| ExprTree * | LookupInScope (const std::string &attrName, const ClassAd *&ad) const |
| Finds the expression bound to an attribute name. | |
Attribute Deletion Methods | |
| void | Clear () |
| Clears the ClassAd of all attributes. | |
| bool | Delete (const std::string &attrName) |
| Deletes the named attribute from the ClassAd. | |
| bool | DeepDelete (const std::string &scopeExpr, const std::string &attrName) |
| Deletes the named attribute from a nested classAd. | |
| bool | DeepDelete (ExprTree *scopeExpr, const std::string &attrName) |
| Deletes the named attribute from a nested classAd. | |
| ExprTree * | Remove (const std::string &attrName) |
| Similar to Delete, but the expression is returned rather than deleted from the classad. | |
| ExprTree * | DeepRemove (const std::string &scopeExpr, const std::string &attrName) |
| Similar to DeepDelete, but the expression is returned rather than deleted from the classad. | |
| ExprTree * | DeepRemove (ExprTree *scopeExpr, const std::string &attrName) |
| Similar to DeepDelete, but the expression is returned rather than deleted from the classad. | |
Evaluation Methods | |
| bool | EvaluateAttr (const std::string &attrName, Value &result) const |
| Evaluates expression bound to an attribute. | |
| bool | EvaluateExpr (const std::string &buf, Value &result) const |
| Evaluates an expression. | |
| bool | EvaluateExpr (const ExprTree *expr, Value &result) const |
| Evaluates an expression. | |
| bool | EvaluateExpr (const ExprTree *expr, Value &result, ExprTree *&sig) const |
| Evaluates an expression, and returns the significant subexpressions encountered during the evaluation. | |
| bool | EvaluateAttrInt (const std::string &attr, int &intValue) const |
| Evaluates an attribute to an integer. | |
| bool | EvaluateAttrReal (const std::string &attr, double &realValue) const |
| Evaluates an attribute to a real. | |
| bool | EvaluateAttrNumber (const std::string &attr, int &intValue) const |
| Evaluates an attribute to an integer. | |
| bool | EvaluateAttrNumber (const std::string &attr, double &realValue) const |
| Evaluates an attribute to a real. | |
| bool | EvaluateAttrString (const std::string &attr, char *buf, int len) const |
| Evaluates an attribute to a string. | |
| bool | EvaluateAttrString (const std::string &attr, std::string &buf) const |
| Evaluates an attribute to a string. | |
| bool | EvaluateAttrBool (const std::string &attr, bool &boolValue) const |
| Evaluates an attribute to a boolean. | |
| bool | EvaluateAttrClassAd (const std::string &attr, ClassAd *&classad) const |
| Evaluates an attribute to a ClassAd. | |
| bool | EvaluateAttrList (const std::string &attr, ExprList *&l) const |
| Evaluates an attribute to an ExprList. | |
Miscellaneous | |
| void | GetComponents (std::vector< std::pair< std::string, ExprTree * > > &vec) const |
| Deconstructor to get the components of a classad. | |
| void | Update (const ClassAd &ad) |
| Make sure everything in the ad is in this ClassAd. | |
| void | Modify (ClassAd &ad) |
| Modify this ClassAd in a specific way Ad is a ClassAd that looks like: [ Context = expr; // Sub-ClassAd to operate on Replace = classad; // ClassAd to Update() replace context Updates = classad; // ClassAd to merge into context (via Update()) Deletes = {a1, a2}; // A list of attribute names to delete from the context. | |
| virtual ExprTree * | Copy () const |
| Makes a deep copy of the ClassAd. | |
| ClassAd & | operator= (const ClassAd &rhs) |
| Make a deep copy of the ClassAd, via the == operator. | |
| bool | CopyFrom (const ClassAd &ad) |
| Fill in this ClassAd with the contents of the other ClassAd. | |
| virtual bool | SameAs (const ExprTree *tree) const |
| Is this ClassAd the same as the tree? Two ClassAds are identical if they have the same number of elements, and each is the SameAs() the other. | |
| bool | Flatten (const ExprTree *expr, Value &val, ExprTree *&fexpr) const |
| Flattens (a partial evaluation operation) the given expression in the context of the classad. | |
| bool | FlattenAndInline (const ExprTree *expr, Value &val, ExprTree *&fexpr) const |
| bool | GetExternalReferences (const ExprTree *tree, References &refs, bool fullNames) |
| Return a list of attribute references in the expression that are not contained within this ClassAd. | |
| bool | GetExternalReferences (const ExprTree *tree, PortReferences &refs) |
| Return a list of attribute references in the expression that are not contained within this ClassAd. | |
| ClassAd * | MakeClassAd (std::vector< std::pair< std::string, ExprTree * > > &vec) |
| Factory method to make a classad. | |
| bool | operator== (ClassAd &list1, ClassAd &list2) |
| Are the two ClassAds the same? Uses SameAs() to decide if they are the same. | |
Deprecated functions (only for use within Condor) | |
| int | Insert (const char *str) |
| Insert an attribute/value into the ClassAd. | |
| int | InsertOrUpdate (const char *expr) |
| Insert an attribute/value into the ClassAd. | |
| int | LookupString (const char *name, char *value) const |
| Lookup (don't evaluate) an attribute that is a string. | |
| int | LookupString (const char *name, char *value, int max_len) const |
| Lookup (don't evaluate) an attribute that is a string. | |
| int | LookupString (const char *name, char **value) const |
| Lookup (don't evaluate) an attribute that is a string. | |
| int | LookupInteger (const char *name, int &value) const |
| Lookup (don't evaluate) an attribute that is an integer. | |
| int | LookupFloat (const char *name, float &value) const |
| Lookup (don't evaluate) an attribute that is a float. | |
| int | LookupBool (const char *name, int &value) const |
| Lookup (don't evaluate) an attribute that can be considered a boolean. | |
| int | LookupBool (const char *name, bool &value) const |
| Lookup (don't evaluate) an attribute that can be considered a boolean. | |
| int | EvalString (const char *name, class ClassAd *target, char *value) |
| Lookup and evaluate an attribute in the ClassAd that is a string. | |
| int | EvalInteger (const char *name, class ClassAd *target, int &value) |
| Lookup and evaluate an attribute in the ClassAd that is an integer. | |
| int | EvalFloat (const char *name, class ClassAd *target, float &value) |
| Lookup and evaluate an attribute in the ClassAd that is a float. | |
| int | EvalBool (const char *name, class ClassAd *target, int &value) |
| Lookup and evaluate an attribute in the ClassAd that is a boolean. | |
| ClassAd (FILE *, char *, int &, int &, int &) | |
| A constructor that reads old ClassAds from a FILE. | |
| void | SetMyTypeName (const char *) |
| Set the MyType attribute. | |
| const char * | GetMyTypeName () |
| Get the value of the MyType attribute. | |
| void | SetTargetTypeName (const char *) |
| Set the value of the TargetType attribute. | |
| const char * | GetTargetTypeName () |
| Get the value of the TargetType attribtute. | |
| int | put (Stream &s) |
| Print the ClassAd as an old ClassAd to the stream. | |
| int | initFromStream (Stream &s) |
| Read the old ClassAd from the stream, and fill in this ClassAd. | |
| virtual int | fPrint (FILE *file) |
| Print the ClassAd as an old ClassAd to the FILE. | |
| void | dPrint (int level) |
| Print the ClassAd as an old ClasAd with dprintf. | |
| bool | AddExplicitConditionals (ExprTree *expr, ExprTree *&newExpr) |
| ClassAd * | AddExplicitTargetRefs () |
Chaining functions | |
| void | ChainToAd (ClassAd *new_chain_parent_ad) |
| Chain this ad to the parent ad. | |
| void | Unchain (void) |
| If we are chained to a parent ad, remove the chain. | |
Friends | |
| class | AttributeReference |
| class | ExprTree |
| class | EvalState |
| class | ClassAdIterator |
|
|
Chain this ad to the parent ad. After chaining, any attribute we look for that is not in this ad will be looked for in the parent ad. This is a simple form of compression: many ads can be linked to a parent ad that contains common attributes between the ads. If an attribute is in both this ad and the parent, a lookup will only show it in the parent. If we make any modifications to this ad, it will not affect the parent.
|
|
|
Makes a deep copy of the ClassAd.
Implements ExprTree. |
|
|
Fill in this ClassAd with the contents of the other ClassAd. This ClassAd is cleared of its contents before the copy happens.
|
|
||||||||||||
|
Deletes the named attribute from a nested classAd. The scope expression is evaluated to obtain a nested classad, and the attribute is then deleted from this ad. Only attributes from the local ClassAd are considered; scoping information is ignored. The expression bound to the attribute is deleted.
|
|
||||||||||||
|
Deletes the named attribute from a nested classAd. The scope expression is evaluated to obtain a nested classad, and the attribute is then deleted from this ad. Only attributes from the local ClassAd are considered; scoping information is ignored. The expression bound to the attribute is deleted.
|
|
||||||||||||||||
|
Inserts an attribute into a nested classAd. The scope expression is evaluated to obtain a nested classad, and the attribute is inserted into this subclassad. The setParentScope() method is invoked on the inserted expression.
|
|
||||||||||||||||
|
Inserts an attribute into a nested classad. The scope expression is evaluated to obtain a nested classad, and the insertion is made in the nested classad. The string value is converted into a Literal expression to yield the expression to be inserted.
|
|
||||||||||||||||
|
Inserts an attribute into a nested classad. The scope expression is evaluated to obtain a nested classad, and the insertion is made in the nested classad. The string value is converted into a Literal expression to yield the expression to be inserted.
|
|
||||||||||||||||
|
Inserts an attribute into a nested classad. The scope expression is evaluated to obtain a nested classad, and the insertion is made in the nested classad. The boolean value is converted into a Literal expression to yield the expression to be inserted.
|
|
||||||||||||||||||||
|
Inserts an attribute into a nested classad. The scope expression is evaluated to obtain a nested classad, and the insertion is made in the nested classad. The double value is converted into a Literal expression to yield the expression to be inserted.
|
|
||||||||||||||||||||
|
Inserts an attribute into a nested classad. The scope expression is evaluated to obtain a nested classad, and the attribute is inserted into this subclassad. The integer value is converted into a Literal expression, and then inserted into the nested classad.
|
|
||||||||||||
|
Similar to DeepDelete, but the expression is returned rather than deleted from the classad.
|
|
||||||||||||
|
Similar to DeepDelete, but the expression is returned rather than deleted from the classad.
|
|
|
Deletes the named attribute from the ClassAd. Only attributes from the local ClassAd are considered; scoping information is ignored. The expression bound to the attribute is deleted.
|
|
|
Print the ClassAd as an old ClasAd with dprintf.
|
|
|
Turn on dirty tracking for this ClassAd. If tracking is on, every insert will label the attribute that was inserted as dirty. Dirty tracking is always turned off during Copy() and CopyFrom(). |
|
||||||||||||||||
|
Lookup and evaluate an attribute in the ClassAd that is a boolean.
|
|
||||||||||||||||
|
Lookup and evaluate an attribute in the ClassAd that is a float.
|
|
||||||||||||||||
|
Lookup and evaluate an attribute in the ClassAd that is an integer.
|
|
||||||||||||||||
|
Lookup and evaluate an attribute in the ClassAd that is a string.
|
|
||||||||||||
|
Evaluates expression bound to an attribute.
|
|
||||||||||||
|
Evaluates an attribute to a boolean. A pointer to the string is returned.
|
|
||||||||||||
|
Evaluates an attribute to a ClassAd. A pointer to the ClassAd is returned. You do not own the ClassAd--do not free it.
|
|
||||||||||||
|
Evaluates an attribute to an integer.
|
|
||||||||||||
|
Evaluates an attribute to an ExprList. A pointer to the ExprList is returned. You do not own the ExprList--do not free it.
|
|
||||||||||||
|
Evaluates an attribute to a real. If the attribute evaluated to an integer, it is promoted to a real.
|
|
||||||||||||
|
Evaluates an attribute to an integer. If the attribute evaluated to a real, it is truncated to an integer.
|
|
||||||||||||
|
Evaluates an attribute to a real.
|
|
||||||||||||
|
Evaluates an attribute to a string. If the string value does not fit into the buffer, only the portion that does fit is copied over.
|
|
||||||||||||||||
|
Evaluates an attribute to a string. If the string value does not fit into the buffer, only the portion that does fit is copied over.
|
|
||||||||||||||||
|
Evaluates an expression, and returns the significant subexpressions encountered during the evaluation. If the expression doesn't already live in this ClassAd, call the setParentScope() method on it first.
|
|
||||||||||||
|
Evaluates an expression. If the expression doesn't already live in this ClassAd, the setParentScope() method must be called on it first.
|
|
||||||||||||
|
Evaluates an expression.
|
|
||||||||||||||||
|
Flattens (a partial evaluation operation) the given expression in the context of the classad.
|
|
|
Print the ClassAd as an old ClassAd to the FILE.
|
|
|
Deconstructor to get the components of a classad.
|
|
||||||||||||
|
Return a list of attribute references in the expression that are not contained within this ClassAd.
|
|
||||||||||||||||
|
Return a list of attribute references in the expression that are not contained within this ClassAd.
|
|
|
Read the old ClassAd from the stream, and fill in this ClassAd.
|
|
|
Insert an attribute/value into the ClassAd.
|
|
||||||||||||
|
Inserts an attribute into the ClassAd. The setParentScope() method is invoked on the inserted expression.
|
|
||||||||||||
|
Inserts an attribute into the ClassAd. The string value is converted into a Literal expression, and then inserted into the classad.
|
|
||||||||||||
|
Inserts an attribute into the ClassAd. The string value is converted into a Literal expression, and then inserted into the classad.
|
|
||||||||||||
|
Inserts an attribute into the ClassAd. The boolean value is converted into a Literal expression, and then inserted into the classad.
|
|
||||||||||||||||
|
Inserts an attribute into the ClassAd. The real value is converted into a Literal expression, and then inserted into the classad.
|
|
||||||||||||||||
|
Inserts an attribute into the ClassAd. The integer value is converted into a Literal expression, and then inserted into the classad.
|
|
|
Insert an attribute/value into the ClassAd.
|
|
|
Return true if an attribute is dirty.
|
|
|
Finds the expression bound to an attribute name. The lookup only involves this ClassAd; scoping information is ignored.
|
|
||||||||||||
|
Lookup (don't evaluate) an attribute that can be considered a boolean.
|
|
||||||||||||
|
Lookup (don't evaluate) an attribute that can be considered a boolean.
|
|
||||||||||||
|
Lookup (don't evaluate) an attribute that is a float.
|
|
||||||||||||
|
Finds the expression bound to an attribute name.
The lookup uses the scoping structure (including
|
|
||||||||||||
|
Lookup (don't evaluate) an attribute that is an integer.
|
|
||||||||||||
|
Lookup (don't evaluate) an attribute that is a string.
|
|
||||||||||||||||
|
Lookup (don't evaluate) an attribute that is a string.
|
|
||||||||||||
|
Lookup (don't evaluate) an attribute that is a string.
|
|
|
Factory method to make a classad.
|
|
|
Mark a particular attribute as not dirty.
|
|
|
Mark a particular attribute as dirty.
|
|
|
Modify this ClassAd in a specific way Ad is a ClassAd that looks like: [ Context = expr; // Sub-ClassAd to operate on Replace = classad; // ClassAd to Update() replace context Updates = classad; // ClassAd to merge into context (via Update()) Deletes = {a1, a2}; // A list of attribute names to delete from the context.
|
|
|
Print the ClassAd as an old ClassAd to the stream.
|
|
|
Similar to Delete, but the expression is returned rather than deleted from the classad.
|
|
|
Is this ClassAd the same as the tree? Two ClassAds are identical if they have the same number of elements, and each is the SameAs() the other. This is a deep comparison.
Implements ExprTree. |
|
|
Make sure everything in the ad is in this ClassAd. This is different than CopyFrom() because we may have many things that the ad doesn't have: we just ensure that everything we import everything from the other ad. This could be called Merge().
|
|
||||||||||||
|
Are the two ClassAds the same? Uses SameAs() to decide if they are the same.
|