@ThingworxExtensionApiClass(since={6,6}, canInstantiate=true) public final class OrganizationalUnit extends NamedObject
NAME_COMPARATOR
Constructor and Description |
---|
OrganizationalUnit() |
Modifier and Type | Method and Description |
---|---|
void |
AddMember(java.lang.String member,
java.lang.String type)
Service Category: Members
Service Description: Add a user/group to this Organizational Unit.
|
void |
AssignMembers(InfoTable members) |
void |
DeleteMember(java.lang.String member,
java.lang.String type) |
static OrganizationalUnit |
fromJSON(org.json.JSONObject jsonObject) |
InfoTable |
GetMember(java.lang.String member) |
EntityReferenceTypeMap |
getMembers() |
InfoTable |
GetMembers() |
InfoTable |
QueryMembers(org.json.JSONObject types,
java.lang.String filter,
java.lang.Double maxItems) |
InfoTable |
toInfoTable() |
org.json.JSONObject |
toJSON() |
getDescription, getName, setDescription, setName, toValueCollection
@ThingworxExtensionApiMethod(since={6,6}) public void AssignMembers(InfoTable members) throws java.lang.Exception
java.lang.Exception
- If an error occurs@ThingworxExtensionApiMethod(since={6,6}) public void AddMember(java.lang.String member, java.lang.String type) throws java.lang.Exception
member
- Member - STRINGtype
- Member type must be set to either User or Group - STRINGjava.lang.Exception
- If an error occurs
Organization.AddMember(name, member, type)
is
also invoked to commit the transaction to the database.
Suggested Use: For performance reasons, use this method to load large number of users or groups to Organizational Units in memory
first, then persist the information at the end using Organization.AddMember(name, member, type)
. For regular addition of a
few individual users or groups, add the members through Organization.AddMember(name, member, type)
instead.@ThingworxExtensionApiMethod(since={6,6}) public void DeleteMember(java.lang.String member, java.lang.String type) throws java.lang.Exception
java.lang.Exception
- If an error occurs@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetMembers() throws java.lang.Exception
java.lang.Exception
- If an error occurs@ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetMember(java.lang.String member) throws java.lang.Exception
java.lang.Exception
- If an error occurs@ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryMembers(org.json.JSONObject types, java.lang.String filter, java.lang.Double maxItems) throws java.lang.Exception
java.lang.Exception
- If an error occurs@ThingworxExtensionApiMethod(since={6,6}) public EntityReferenceTypeMap getMembers()
@ThingworxExtensionApiMethod(since={6,6}) public InfoTable toInfoTable()
@ThingworxExtensionApiMethod(since={6,6}) public static OrganizationalUnit fromJSON(org.json.JSONObject jsonObject) throws java.lang.Exception
java.lang.Exception
- If an error occurs@ThingworxExtensionApiMethod(since={6,6}) public org.json.JSONObject toJSON() throws java.lang.Exception
java.lang.Exception
- If an error occurs