30 #ifndef GOOGLE_CONTAINER_API_RESOURCE_LIMIT_H_ 31 #define GOOGLE_CONTAINER_API_RESOURCE_LIMIT_H_ 34 #include "googleapis/base/integral_types.h" 35 #include "googleapis/base/macros.h" 36 #include "googleapis/client/data/jsoncpp_data.h" 37 #include "googleapis/strings/stringpiece.h" 86 return StringPiece(
"google_container_api::ResourceLimit");
95 return Storage().isMember(
"maximum");
102 MutableStorage()->removeMember(
"maximum");
110 const Json::Value& storage = Storage(
"maximum");
111 return client::JsonValueToCppValueHelper<int64 >(storage);
122 client::SetJsonValueFromCppValueHelper<int64 >(
123 value, MutableStorage(
"maximum"));
132 return Storage().isMember(
"minimum");
139 MutableStorage()->removeMember(
"minimum");
147 const Json::Value& storage = Storage(
"minimum");
148 return client::JsonValueToCppValueHelper<int64 >(storage);
159 client::SetJsonValueFromCppValueHelper<int64 >(
160 value, MutableStorage(
"minimum"));
169 return Storage().isMember(
"resourceType");
176 MutableStorage()->removeMember(
"resourceType");
184 const Json::Value& v = Storage(
"resourceType");
185 if (v == Json::Value::null)
return StringPiece(
"");
186 return StringPiece(v.asCString());
197 *MutableStorage(
"resourceType") = value.data();
204 #endif // GOOGLE_CONTAINER_API_RESOURCE_LIMIT_H_ int64 get_minimum() const
Definition: resource_limit.h:146
bool has_resource_type() const
Definition: resource_limit.h:168
void set_minimum(int64 value)
Definition: resource_limit.h:158
bool has_maximum() const
Definition: resource_limit.h:94
Definition: resource_limit.h:52
const StringPiece GetTypeName() const
Definition: resource_limit.h:85
void clear_maximum()
Definition: resource_limit.h:101
bool has_minimum() const
Definition: resource_limit.h:131
int64 get_maximum() const
Definition: resource_limit.h:109
void set_maximum(int64 value)
Definition: resource_limit.h:121
Definition: accelerator_config.h:39
Definition: accelerator_config.cc:41
void clear_resource_type()
Definition: resource_limit.h:175
void set_resource_type(const StringPiece &value)
Definition: resource_limit.h:196
void clear_minimum()
Definition: resource_limit.h:138
const StringPiece get_resource_type() const
Definition: resource_limit.h:183