use of com.aliyuncs.fc.model.FunctionCodeMetadata in project fc-java-sdk by aliyun.
the class FunctionComputeClient method getFunctionCode.
public GetFunctionCodeResponse getFunctionCode(GetFunctionCodeRequest request) throws ClientException, ServerException {
HttpResponse response = client.doAction(request, CONTENT_TYPE_APPLICATION_JSON, "GET");
FunctionCodeMetadata functionCodeMetadata = GSON.fromJson(new String(response.getContent()), FunctionCodeMetadata.class);
GetFunctionCodeResponse getFunctionCodeResponse = new GetFunctionCodeResponse();
getFunctionCodeResponse.setFunctionCodeMetadata(functionCodeMetadata);
getFunctionCodeResponse.setHeader(response.getHeaders());
getFunctionCodeResponse.setContent(response.getContent());
getFunctionCodeResponse.setStatus(response.getStatus());
return getFunctionCodeResponse;
}
Aggregations