use of com.cloud.api.response.ResourceTagResponse in project cosmic by MissionCriticalCloud.
the class ResourceTagJoinDaoImpl method newResourceTagResponse.
@Override
public ResourceTagResponse newResourceTagResponse(final ResourceTagJoinVO resourceTag, final boolean keyValueOnly) {
final ResourceTagResponse response = new ResourceTagResponse();
response.setKey(resourceTag.getKey());
response.setValue(resourceTag.getValue());
if (!keyValueOnly) {
response.setResourceType(resourceTag.getResourceType().toString());
response.setResourceId(resourceTag.getResourceUuid());
ApiResponseHelper.populateOwner(response, resourceTag);
response.setDomainId(resourceTag.getDomainUuid());
response.setDomainName(resourceTag.getDomainName());
response.setCustomer(resourceTag.getCustomer());
}
response.setObjectName("tag");
return response;
}
Aggregations