pdk.Properties ($Date: 2002/12/04 10:13:05 $)
index
pdk/Properties.py

Property classes.

pdk properties are variables (in the sense defined in the pdk.Variables module) used as instance attributes. The classes in this module only make sense in conjunction with the property manager classes in the pdk.PropertyManagers module, which also provide more documentation.

This code incorporates ideas taken from Graphite, which was originally written by Joseph and Michelle Strout in 1999.

FOG 08.2001

 
Classes
            
_Property
AnyProperty(_Property, pdk.Variables.Variable)
AnyProperty(_Property, pdk.Variables.Variable)
ArrayProperty(_Property, pdk.Variables.ArrayVariable)
BooleanProperty(_Property, pdk.Variables.BooleanVariable)
CharProperty(_Property, pdk.Variables.CharVariable)
DateTimeProperty(_Property, pdk.Variables.DateTimeVariable)
EnumProperty(_Property, pdk.Variables.EnumVariable)
FloatProperty(_Property, pdk.Variables.FloatVariable)
FunctionProperty(_Property, pdk.Variables.FunctionVariable)
InstanceProperty(_Property, pdk.Variables.InstanceVariable)
IntProperty(_Property, pdk.Variables.IntVariable)
MappingProperty(_Property, pdk.Variables.MappingVariable)
MappingProperty(_Property, pdk.Variables.MappingVariable)
NumberProperty(_Property, pdk.Variables.NumberVariable)
PositionProperty(_Property, pdk.Variables.PositionVariable)
PropertyGroup(_Property, pdk.Variables.VariableGroup)
RectangleProperty(_Property, pdk.Variables.RectangleVariable)
SequenceProperty(_Property, pdk.Variables.SequenceVariable)
SequenceProperty(_Property, pdk.Variables.SequenceVariable)
StringProperty(_Property, pdk.Variables.StringVariable)
TupleProperty(_Property, pdk.Variables.TupleVariable)
 
class AnyProperty(_Property, pdk.Variables.Variable)
     
Purpose: implements a generic property that can hold any value

 
  
Method resolution order:
AnyProperty
_Property
pdk.Variables.Variable
pdk.Base.OptionHandler

Methods defined here:
acceptable(self, value)
 
class ArrayProperty(_Property, pdk.Variables.ArrayVariable)
     
Purpose:implements an array property

 
  
Method resolution order:
ArrayProperty
_Property
pdk.Variables.ArrayVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class BooleanProperty(_Property, pdk.Variables.BooleanVariable)
     
Purpose:implements a boolean property

 
  
Method resolution order:
BooleanProperty
_Property
pdk.Variables.BooleanVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class CharProperty(_Property, pdk.Variables.CharVariable)
     
Purpose:implements a char property

 
  
Method resolution order:
CharProperty
_Property
pdk.Variables.CharVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class DateTimeProperty(_Property, pdk.Variables.DateTimeVariable)
     
Purpose:implements a date/time property

 
  
Method resolution order:
DateTimeProperty
_Property
pdk.Variables.DateTimeVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
DictionaryProperty = class MappingProperty(_Property, pdk.Variables.MappingVariable)
     
Purpose:implements a mapping property

 
  
Method resolution order:
MappingProperty
_Property
pdk.Variables.MappingVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class EnumProperty(_Property, pdk.Variables.EnumVariable)
     
Purpose:implements an enumeration property

 
  
Method resolution order:
EnumProperty
_Property
pdk.Variables.EnumVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class FloatProperty(_Property, pdk.Variables.FloatVariable)
     
Purpose:implements an float property

 
  
Method resolution order:
FloatProperty
_Property
pdk.Variables.FloatVariable
pdk.Variables.NumberVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class FunctionProperty(_Property, pdk.Variables.FunctionVariable)
     
Purpose:implements a function property

 
  
Method resolution order:
FunctionProperty
_Property
pdk.Variables.FunctionVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class InstanceProperty(_Property, pdk.Variables.InstanceVariable)
     
Purpose:implements a instance property

 
  
Method resolution order:
InstanceProperty
_Property
pdk.Variables.InstanceVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class IntProperty(_Property, pdk.Variables.IntVariable)
     
Purpose:implements an integer property

 
  
Method resolution order:
IntProperty
_Property
pdk.Variables.IntVariable
pdk.Variables.NumberVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
ListProperty = class SequenceProperty(_Property, pdk.Variables.SequenceVariable)
     
Purpose:implements a sequence property

 
  
Method resolution order:
SequenceProperty
_Property
pdk.Variables.SequenceVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class MappingProperty(_Property, pdk.Variables.MappingVariable)
     
Purpose:implements a mapping property

 
  
Method resolution order:
MappingProperty
_Property
pdk.Variables.MappingVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class NumberProperty(_Property, pdk.Variables.NumberVariable)
     
Purpose:implements a number property

 
  
Method resolution order:
NumberProperty
_Property
pdk.Variables.NumberVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class PositionProperty(_Property, pdk.Variables.PositionVariable)
     
Purpose:implements a position property

 
  
Method resolution order:
PositionProperty
_Property
pdk.Variables.PositionVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
Property = class AnyProperty(_Property, pdk.Variables.Variable)
     
Purpose: implements a generic property that can hold any value

 
  
Method resolution order:
AnyProperty
_Property
pdk.Variables.Variable
pdk.Base.OptionHandler

Methods defined here:
acceptable(self, value)
 
class PropertyGroup(_Property, pdk.Variables.VariableGroup)
     
Purpose:implements "or" operations on properties

 
  
Method resolution order:
PropertyGroup
_Property
pdk.Variables.VariableGroup
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class RectangleProperty(_Property, pdk.Variables.RectangleVariable)
     
Purpose:implements a rectangle property

 
  
Method resolution order:
RectangleProperty
_Property
pdk.Variables.RectangleVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class SequenceProperty(_Property, pdk.Variables.SequenceVariable)
     
Purpose:implements a sequence property

 
  
Method resolution order:
SequenceProperty
_Property
pdk.Variables.SequenceVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class StringProperty(_Property, pdk.Variables.StringVariable)
     
Purpose:implements a string property

 
  
Method resolution order:
StringProperty
_Property
pdk.Variables.StringVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class TupleProperty(_Property, pdk.Variables.TupleVariable)
     
Purpose:implements a tuple property

 
  
Method resolution order:
TupleProperty
_Property
pdk.Variables.TupleVariable
pdk.Variables.SequenceVariable
pdk.Variables.Variable
pdk.Base.OptionHandler
 
class _Property
       
   Methods defined here:
__or__(self, other)
__ror__ = __or__(self, other)
extend(self, otherProperty)
this method is called when the property manager traverses the inheritance tree for a property. self is extended with otherProperty.
getCallbacks(self)
getDelCallback(self)
getGetCallback(self)
getSetPostCallback(self)
getSetPreCallback(self)
isAutoInit(self, autoInitFlag=None)
isExtensible(self, extensibleFlag=None)
isReadOnly(self, readOnlyFlag=None)
setDelCallback(self, delCallbackF)
setGetCallback(self, getCallbackF)
setSetPostCallback(self, modifyCallbackF)
setSetPreCallback(self, validateCallbackF)

Data and non-method functions defined here:
OPTIONS = {'AUTOINIT': 1, 'DELCALLBACK': None, 'EXTEND': 0, 'GETCALLBACK': None, 'READONLY': 0, 'SETPOSTCALLBACK': None, 'SETPRECALLBACK': None}
 
Functions
            
is_property(obj)
checks if obj is an instance of _Property.
 
Author
            
$Author: gathmann $