<s> from openstack . compute import compute_service <EOL> from openstack import resource <EOL> class AbsoluteLimits ( resource . Resource ) : <EOL> image_meta = resource . prop ( "<STR_LIT>" ) <EOL> personality = resource . prop ( "<STR_LIT>" ) <EOL> personality_size = resource . prop ( "<STR_LIT>" ) <EOL> security_group_rules = resource . prop ( "<STR_LIT>" ) <EOL> security_groups = resource . prop ( "<STR_LIT>" ) <EOL> security_groups_used = resource . prop ( "<STR_LIT>" ) <EOL> server_meta = resource . prop ( "<STR_LIT>" ) <EOL> total_cores = resource . prop ( "<STR_LIT>" ) <EOL> total_cores_used = resource . prop ( "<STR_LIT>" ) <EOL> floating_ips = resource . prop ( "<STR_LIT>" ) <EOL> floating_ips_used = resource . prop ( "<STR_LIT>" ) <EOL> instances = resource . prop ( "<STR_LIT>" ) <EOL> instances_used = resource . prop ( "<STR_LIT>" ) <EOL> keypairs = resource . prop ( "<STR_LIT>" ) <EOL> total_ram = resource . prop ( "<STR_LIT>" ) <EOL> total_ram_used = resource . prop ( "<STR_LIT>" ) <EOL> server_groups = resource . prop ( "<STR_LIT>" ) <EOL> server_groups_used = resource . prop ( "<STR_LIT>" ) <EOL> server_group_members = resource . prop ( "<STR_LIT>" ) <EOL> class RateLimits ( resource . Resource ) : <EOL> limits = resource . prop ( "<STR_LIT>" , type = list ) <EOL> regex = resource . prop ( "<STR_LIT>" ) <EOL> uri = resource . prop ( "<STR_LIT>" ) <EOL> class Limits ( resource . Resource ) : <EOL> base_path = "<STR_LIT>" <EOL> resource_key = "<STR_LIT>" <EOL> service = compute_service . ComputeService ( ) <EOL> allow_retrieve = True <EOL> absolute = resource . prop ( "<STR_LIT>" , type = AbsoluteLimits ) <EOL> rate = resource . prop ( "<STR_LIT>" , type = list ) <EOL> def get ( self , session , args = None , include_headers = False ) : <EOL> """<STR_LIT>""" <EOL> body = self . get_data_by_id ( session , self . id , <EOL> include_headers = include_headers ) <EOL> rate_body = body . pop ( "<STR_LIT>" ) <EOL> self . _attrs . update ( body ) <EOL> rates = [ ] <EOL> for rate in rate_body : <EOL> rates . append ( RateLimits ( rate ) ) <EOL> self . _attrs . update ( { "<STR_LIT>" : rates } ) <EOL> self . _loaded = True <EOL> return self </s>
