IID_IMoaMmPropertyReference
PIMoaMmPropertyReference
IMoaUnknown
ImoaMmPropertyReference
methods provide a way for a Director Object inspector to get
information on the actual properties (not just their values) that
your Xtra implements. For your Xtra to be compatible with the Object
inspector, your Xtra needs to provide these interfaces.
Note: Director does not call these methods. They are reserved for future use.
kMoaMmErr_AccessNotSupported
if you do not want
to support these capabilities.
- AccessPropRef(PIMoaMmPropertyReference This,
- ConstPMoaMmValue selfRef,
- MoaMmSymbol propName,
- MoaLong indexCount,
- ConstPMoaMmValue pIndexValues,
- PMoaMmValue pResult)
This
IMoaMmPropertyReference
interfaceselfRef
ConstPMoaMmValue
The property reference object, as a Lingo value. Assign to pResult
and AddRef to return self.propName
MoaMmSymbol
The property name to look upindexCount
MoaLong
The number of indices. Specify 0, 1, or 2.pIndexValues
ConstPMoaMmValue
An array of indicespResult
PMoaMmValue
Optional return value. To return a new property reference Lingo object, use IMoaMmPropReferenceValue::PropReferenceToValue.MoaError:
kMoaMmErr_PropertyNotFound | The property is not found. |
kMoaMmErr_AccessNotSupported | If your Xtra does not support cascaded property access, return this. |
AccessPropRef
calls, up to the last access which will be any of GetProp
, SetProp
, SetContents
, SetBefore
, or SetAfter
.
put x.sel[33].foo --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} ) --> i.GetProp( propName=foo, indexCount=0 ) put x.sel[33].foo[10] --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} ) --> i.GetProp( propName=#foo, indexCount=1, pIndexValues={10} ) set x.sel[33].foo[9..11] = "Done!" --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} ) --> i.SetProp( propName=#foo, indexCount=2, pIndexValues={9,11}, pNewValue="Done!" )
- CallHandler(PIMoaMmPropertyReference This,
- PMoaMmCallInfo callPtr)
This
IMoaMmPropertyReference
interfacecallPtr
PMoaMmCallInfo
MoaError:
kMoaMmErr_FunctionNotFound | If you do not support the handler call. |
x.sel[1].goDown(99) --> AccesProp( propName=#sel, indexCount=1, pIndexValues={1}) --> CallHandlers( callPtr->nargs=2, args={instance, 99} )
- GetContents(PIMoaMmPropertyReference This,
- ConstPMoaMmValue selfRef,
- PMoaMmValue pResult)
This
IMoaMmPropertyReference
interfaceselfRef
ConstPMoaMmValue
The property reference object, as a Lingo value. Assign to pResult
and AddRef to return self.pResult
PMoaMmValue
The return valueMoaError
put
command.
Note: This method is not used by Director 7 or eariler. It is reserved for future versions.
put "Banana" into x.sel[33].foo --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} )
- GetCount(PIMoaMmPropertyReference This,
- MoaMmSymbol propName,
- MoaLong * pCount)
This
IMoaMmPropertyReference
interfacepropName
MoaMmSymbol
The name of the property to look uppCount
MoaLong *
The return countMoaError:
kMoaMmErr_PropertyNotFound | The property is not found. |
kMoaMmErr_AccessNotSupported | The property is not countable. |
propName
.
put x.word.count --> i.GetCount(propName=#word).
- GetProp(PIMoaMmPropertyReference This,
- ConstPMoaMmValue selfRef,
- MoaMmSymbol propName,
- MoaLong indexCount,
- ConstPMoaMmValue pIndexValues,
- PMoaMmValue pResult)
This
IMoaMmPropertyReference
interfaceselfRef
ConstPMoaMmValue
The property reference object, as a Lingo value. Assign this to pResult
and AddRef to return the same property reference. Use this parameter to support properties that are further references as opposed to final values.propName
MoaMmSymbol
The property name to look upindexCount
MoaLong
The number of indices. Specify 0, 1, or 2.pIndexValues
ConstPMoaMmValue
An array of indicespResult
PMoaMmValue
The return valueMoaError:
kMoaMmErr_PropertyNotFound | The property is not found. |
kMoaMmErr_AccessNotSupported | If your Xtra does not support property access, then return this. (If you do not support indexCount values greater than 0, for example.) |
put x.foo --> i.GetProp( propName=foo, indexCount=0 ) put x.foo[10] --> i.GetProp( propName=#foo, indexCount=1, pIndexValues={10} ) put x.foo[9..11] --> i.GetProp( propName=#foo, indexCount=2, pIndexValues={9,11} )
- GetPropCount(PIMoaMmPropertyReference This,
- MoaLong * pCount)
This
IMoaMmPropertyReference
interfacepCount
MoaLong *
MoaError
- GetPropNameByIndex(PIMoaMmPropertyReference This,
- MoaLong index,
- PMoaMmSymbol pSymbol)
This
IMoaMmPropertyReference
interfaceindex
MoaLong
pSymbol
PMoaMmSymbol
MoaError
- GetPropTypeByIndex(PIMoaMmPropertyReference This,
- MoaLong index,
- PMoaMmValue pType)
This
IMoaMmPropertyReference
interfaceindex
MoaLong
pType
PMoaMmValue
MoaError
- SetContents(PIMoaMmPropertyReference This,
- ConstPMoaMmValue selfRef,
- PMoaMmValue pResult)
This
IMoaMmPropertyReference
interfaceselfRef
ConstPMoaMmValue
The new value to stuff into the targetpResult
PMoaMmValue
MoaError
put-into
command.
put "Banana" into x.sel[33].foo --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} ) --> i.SetContents( pNewValue="Banana" )
- SetContentsAfter(PIMoaMmPropertyReference This,
- PMoaMmValue pNewValue)
This
IMoaMmPropertyReference
interfacepNewValue
PMoaMmValue
The new value to stuff into the targetMoaError
put-after
command.
put "Banana" before x.sel[33].foo --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} ) --> i.SetContents( pNewValue="Banana" )
- SetContentsBefore(PIMoaMmPropertyReference This,
- PMoaMmValue pNewValue)
This
IMoaMmPropertyReference
interfacepNewValue
PMoaMmValue
The new value to stuff into the targetMoaError
put "Banana" before x.sel[33].foo --> i.AccessProp(propName=#sel, indexCount=1, pIndexValues={33} ) --> i.SetContents( pNewValue="Banana" )
- SetProp(PIMoaMmPropertyReference This,
- MoaMmSymbol propName,
- MoaLong indexCount,
- ConstPMoaMmValue pIndexValues,
- ConstPMoaMmValue pNewValue)
This
IMoaMmPropertyReference
interfacepropName
MoaMmSymbol
The property name to look upindexCount
MoaLong
The number of indices. Specify 0, 1, or 2.pIndexValues
ConstPMoaMmValue
An array of indicespNewValue
ConstPMoaMmValue
The new value to assignMoaError:
kMoaMmErr_PropertyNotFound | The property is not found. |
kMoaMmErr_AccessNotSupported | If your Xtra does not support property access, then return this. (If you do not support indexCount values greater than 0, for example.)
|
kMoaMmErr_CannotSetProperty | Set not allowed on specified property. |
set x.foo = 99 --> i.SetProp( propName=foo, indexCount=0, pNewValue=99 ) set x.foo[10] = 99 --> i.GetProp( propName=#foo, indexCount=1, pIndexValues={10}, pNewValue=99 ) set x.foo[9..11] = 123 --> i.GetProp( propName=#foo, indexCount=2, pIndexValues={9,11}, pNewValue=123 )