2024 April Release

Interface CooObject Permanent link for this heading

This interface describes methods available when working with objects.

Methods Permanent link for this heading

Return Type

Signature

boolean

CheckAccess(
  transaction transaction,
  object accesstype,
  optional boolean showerror)

boolean

CheckAccessEx(
  transaction transaction,
  object accesstype,
  object user,
  optional object rolegroup,
  optional object roleposition,
  optional object clientdomain,
  optional object secclearance)

boolean

CheckAggregateSetAccess(
  transaction transaction,
  object attributedefinition,
  aggregate aggregate,
  optional boolean showerror)

boolean

CheckGetAccess(
  transaction transaction,
  optional object attributedefinition,
  optional boolean showerror)

boolean

CheckGetSecured(
  object attributedefinition,
  optional boolean showerror)

boolean

CheckSetAccess(
  transaction transaction,
  optional object attributedefinition,
  optional boolean showerror)

boolean

CheckSetSecured(
  object attributedefinition,
  optional boolean showerror)

boolean

Compare(
  object object)

boolean

ContainsAttributeValue(
  transaction transaction,
  object attributedefinition,
  any value)

string

GetAddress(
  optional  reserved)

object

GetAspect()

any[]

GetAttribute(
  transaction transaction,
  object attributedefinition)

string

GetAttributeString(
  transaction transaction,
  object attributedefinition,
  optional object language)

string

GetAttributeStringEx(
  transaction transaction,
  object attributedefinition,
  optional object language,
  optional object[] attributedefinitionlist,
  optional integer flags)

any

GetAttributeValue(
  transaction transaction,
  object attributedefinition,
  optional integer inx)

integer

GetAttributeValueCount(
  transaction transaction,
  object attributedefinition)

object

GetClass()

integer

GetCoostID()

integer

GetDomainMajorID()

integer

GetDomainMinorID()

integer

GetID()

string

GetIdentification(
  optional  reserved)

string

GetName(
  optional transaction transaction)

integer

GetObjID()

string

GetReference(
  optional  reserved)

string

GetShortReference(
  optional  reserved)

string

GetSimpleReference(
  optional  reserved)

datetime

GetVersDate()

integer

GetVersNr()

boolean

HasAttribute(
  transaction transaction,
  object attributedefinition)

boolean

HasAttributeValue(
  transaction transaction,
  object attributedefinition,
  optional integer inx)

boolean

HasClass(
  object objectclass...)

boolean

IsClass(
  object objectclass...)

boolean

IsUsable(
  optional object objectclass...)

void

LoadAllAttributes(
  transaction transaction)

void

LoadSpecificAttributes(
  transaction transaction,
  object[] attributedefinitionlist)

Methods Permanent link for this heading


CheckAccess Permanent link for this heading

Checks an access type for the object.

boolean CheckAccess(
  transaction transaction,
  object accesstype,
  optional boolean showerror)

Name

Description

transaction

accesstype

showerror

Show an error instead of setting the return value.

CheckAccessEx Permanent link for this heading

Checks an access type for the object with a certain user/domain/role.

boolean CheckAccessEx(
  transaction transaction,
  object accesstype,
  object user,
  optional object rolegroup,
  optional object roleposition,
  optional object clientdomain,
  optional object secclearance)

Name

Description

transaction

accesstype

user

rolegroup

roleposition

clientdomain

secclearance


CheckAggregateSetAccess Permanent link for this heading

Checks set access for a single line of an aggregate of the object.

boolean CheckAggregateSetAccess(
  transaction transaction,
  object attributedefinition,
  aggregate aggregate,
  optional boolean showerror)

Name

Description

transaction

attributedefinition

aggregate

showerror

Fail on invalid input

CheckGetAccess Permanent link for this heading

Checks get access for an attribute of the object.

boolean CheckGetAccess(
  transaction transaction,
  optional object attributedefinition,
  optional boolean showerror)

Name

Description

transaction

attributedefinition

The attribute definition which should be checked.

showerror

Show an error instead of setting the return value.

CheckGetSecured Permanent link for this heading

Checks secured get access for an attribute of the object.

boolean CheckGetSecured(
  object attributedefinition,
  optional boolean showerror)

Name

Description

attributedefinition

The attribute definition which should be checked.

showerror

Show an error instead of setting the return value.

CheckSetAccess Permanent link for this heading

Checks set access for an attribute of the object.

boolean CheckSetAccess(
  transaction transaction,
  optional object attributedefinition,
  optional boolean showerror)

Name

Description

transaction

attributedefinition

The attribute definition which should be checked.

showerror

Show an error instead of setting the return value.

CheckSetSecured Permanent link for this heading

Checks secured set access for an attribute of the object.

boolean CheckSetSecured(
  object attributedefinition,
  optional boolean showerror)

Name

Description

attributedefinition

The attribute definition which should be checked.

showerror

Show an error instead of setting the return value.

Compare Permanent link for this heading

Returns true if this object has the same identity as the passed object.
Note: This method does not compare the object properties.

boolean Compare(
  object object)

Name

Description

object


ContainsAttributeValue Permanent link for this heading

Tests whether the attribute contains a specific value.

boolean ContainsAttributeValue(
  transaction transaction,
  object attributedefinition,
  any value)

Name

Description

transaction

The transaction to be used (e.g. cootx for the current one).
Might be null for checking directly without transaction.

attributedefinition

The definition of the attribute on the object to be checked for values.

value

Only scalar values of type boolean, datetime, enum, float, integer, object and string are supported.

GetAddress Permanent link for this heading

Retrieves the address of the object.

string GetAddress(
  optional  reserved)

Name

Description

reserved


GetAspect Permanent link for this heading

Retrieves the object aspect of the object.

object GetAspect()


GetAttribute Permanent link for this heading

Retrieves all values of the attribute.

any[] GetAttribute(
  transaction transaction,
  object attributedefinition)

Name

Description

transaction

attributedefinition


GetAttributeString Permanent link for this heading

Retrieves the value of the attribute as string.

string GetAttributeString(
  transaction transaction,
  object attributedefinition,
  optional object language)

Name

Description

transaction

attributedefinition

language


GetAttributeStringEx Permanent link for this heading

Retrieves the value of the attribute as string.

string GetAttributeStringEx(
  transaction transaction,
  object attributedefinition,
  optional object language,
  optional object[] attributedefinitionlist,
  optional integer flags)

Name

Description

transaction

attributedefinition

language

attributedefinitionlist

flags


GetAttributeValue Permanent link for this heading

Retrieves a specific value of the attribute.

any GetAttributeValue(
  transaction transaction,
  object attributedefinition,
  optional integer inx)

Name

Description

transaction

attributedefinition

inx


GetAttributeValueCount Permanent link for this heading

Retrieves the number of values of the attribute.

integer GetAttributeValueCount(
  transaction transaction,
  object attributedefinition)

Name

Description

transaction

attributedefinition


GetClass Permanent link for this heading

Retrieves the object class of the object.

object GetClass()


GetCoostID Permanent link for this heading

Retrieves the coo store id of the object.

integer GetCoostID()


GetDomainMajorID Permanent link for this heading

Retrieves the domain major id of the object.

integer GetDomainMajorID()


GetDomainMinorID Permanent link for this heading

Retrieves the domain minor id of the object.

integer GetDomainMinorID()


GetID Permanent link for this heading

Retrieves the id of the object.

integer GetID()


GetIdentification Permanent link for this heading

Retrieves the identification of the object.

string GetIdentification(
  optional  reserved)

Name

Description

reserved


GetName Permanent link for this heading

Retrieves the name of the object.

string GetName(
  optional transaction transaction)

Name

Description

transaction


GetObjID Permanent link for this heading

Retrieves the object id of the object.

integer GetObjID()


GetReference Permanent link for this heading

Retrieves the reference of the object.

string GetReference(
  optional  reserved)

Name

Description

reserved


GetShortReference Permanent link for this heading

Retrieves the short reference of the object, which means that the component part is omitted for system objects.

string GetShortReference(
  optional  reserved)

Name

Description

reserved


GetSimpleReference Permanent link for this heading

Retrieves the simple reference of the object, which means that all separators are replaced by an underscore and that the component part is omitted for system objects.

string GetSimpleReference(
  optional  reserved)

Name

Description

reserved


GetVersDate Permanent link for this heading

Retrieves the version date and time of the object.

datetime GetVersDate()


GetVersNr Permanent link for this heading

Retrieves the version number of the object.

integer GetVersNr()


HasAttribute Permanent link for this heading

Tests whether the attribute is defined.

boolean HasAttribute(
  transaction transaction,
  object attributedefinition)

Name

Description

transaction

attributedefinition


HasAttributeValue Permanent link for this heading

Tests whether the attribute has a value.

boolean HasAttributeValue(
  transaction transaction,
  object attributedefinition,
  optional integer inx)

Name

Description

transaction

attributedefinition

inx


HasClass Permanent link for this heading

Returns true if the object is an instance of one of the passed object classes.

boolean HasClass(
  object objectclass...)

Name

Description

objectclass...


IsClass Permanent link for this heading

Returns true if the object is one of the passed object classes or derived from at leaset one of the passed object classes.

boolean IsClass(
  object objectclass...)

Name

Description

objectclass...


IsUsable Permanent link for this heading

Checks whether the object is usable, i.e. the object is an instance of one of the passed object classes, is not deleted, and the current user has at least read access to the object.
If the object is temporarily unavailable (e.g. the object's service is temporarily unavailable), the function returns false without an error. Accordingly, the result should not be persisted without further checks (e.g. whether the object class can be read).
If no object class is passed as a parameter, the object class Object is used as default.
This function can be used to optimize terms like
obj.HasClass(#Object) && !cootx.IsDeleted(obj) && CheckAccess(cootx, #AccTypeRead) && !obj.objdeleted

boolean IsUsable(
  optional object objectclass...)

Name

Description

objectclass...


LoadAllAttributes Permanent link for this heading

Loads all attributes for the object.

void LoadAllAttributes(
  transaction transaction)

Name

Description

transaction


LoadSpecificAttributes Permanent link for this heading

Loads specific attributes for the object.

void LoadSpecificAttributes(
  transaction transaction,
  object[] attributedefinitionlist)

Name

Description

transaction

attributedefinitionlist