DeleteGroupEntity
Delete an entity in the group.
Service | Operation |
---|---|
group | DELETE_GROUP_ENTITY |
Method Parameters
Parameter | Description |
---|---|
groupId | ID of the group |
entityId | ID of the entity. |
version | The current version of the group entity (for concurrency checking). |
Usage
http://localhost:3000
- C#
- C++
- Objective-C
- Java
- JavaScript
- Dart
- Cloud Code
- Raw
string groupId = "a-group-id";
string entityId = "a-group-entity-id";
int version = 3;
SuccessCallback successCallback = (response, cbObject) =>
{
Debug.Log(string.Format("Success | {0}", response));
};
FailureCallback failureCallback = (status, code, error, cbObject) =>
{
Debug.Log(string.Format("Failed | {0} {1} {2}", status, code, error));
};
_bc.Group.DeleteGroupEntity(groupId, entityId, version, successCallback, failureCallback);
const char *groupId = "a-group-id";
const char *entityId = "a-group-entity-id";
int version = 3;
_bc->getGroup()->deleteGroupEntity(groupId, entityId, version, this);
NSString *groupId = @"a-group-id";
NSString *entityId = @"a-group-entity-id";
int version = 3;
BCCompletionBlock successBlock; // define callback
BCErrorCompletionBlock failureBlock; // define callback
[[_bc groupService] deleteGroupEntity:groupId
entityId:entityId
version:version
completionBlock:successBlock
errorCompletionBlock:failureBlock
cbObject:nil];
String groupId = "a-group-id";
String entityId = "a-group-entity-id";
int version = 3;
this; // implements IServerCallback
_bc.getGroup().deleteGroupEntity(groupId, entityId, version, this);
public void serverCallback(ServiceName serviceName, ServiceOperation serviceOperation, JSONObject jsonData)
{
System.out.print(String.format("Success | %s", jsonData.toString()));
}
public void serverError(ServiceName serviceName, ServiceOperation serviceOperation, int statusCode, int reasonCode, String jsonError)
{
System.out.print(String.format("Failed | %d %d %s", statusCode, reasonCode, jsonError.toString()));
}
var groupId = "a-group-id";
var entityId = "a-group-entity-id";
var version = 3;
_bc.group.deleteGroupEntity(groupId, entityId, version, result =>
{
var status = result.status;
console.log(status + " : " + JSON.stringify(result, null, 2));
});
var groupId = "a-group-id";
var entityId = "a-group-entity-id";
var version = 3;
ServerResponse result = await _bc.groupService.deleteGroupEntity(groupId:groupId, entityId:entityId, version:version);
if (result.statusCode == 200) {
print("Success");
} else {
print("Failed ${result.error['status_message'] ?? result.error}");
}
var groupId = "a-group-id";
var entityId = "a-group-entity-id";
var version = 3;
var groupProxy = bridge.getGroupServiceProxy();
var postResult = groupProxy.deleteGroupEntity(groupId, entityId, version);
if (postResult.status == 200) {
// Success!
}
{
"service": "group",
"operation": "DELETE_GROUP_ENTITY",
"data": {
"groupId": "a-group-id",
"entityId": "a-group-entity-id",
"version": 3
}
}
JSON Response
{
"status": 200,
"data": null
}