getObjectAttribute()

Overview

public any function getObjectAttribute(
      required string objectName   
    , required string attributeName
    ,          string defaultValue  = ""
)

Returns an arbritary attribute value that is defined on the object's :code:component tag.

Arguments

NameTypeRequiredDescription
objectNamestringYesName of the object whose attribute we wish to get
attributeNamestringYesName of the attribute whose value we wish to get
defaultValuestringNo (default="")Default value for the attribute, should it not exist

Example

eventLabelField = presideObjectService.getObjectAttribute(
          objectName    = "event"
        , attributeName = "labelField"
        , defaultValue  = "label"
);