@@ -50,18 +50,20 @@ class Attribute(BaseResource):
5050 'trafficTypeId' : 'string' ,
5151 'displayName' : 'string' ,
5252 'description' : 'string' ,
53- 'dataType' : 'string'
53+ 'dataType' : 'string' ,
54+ 'isSearchable' : 'string' ,
5455 }
5556
5657 def __init__ (self , client , id , traffic_type_id , display_name = None ,
57- description = None , data_type = None ):
58+ description = None , data_type = None , is_searchable = None ):
5859 '''
5960 '''
6061 BaseResource .__init__ (self , client , id )
6162 self ._traffic_type_id = traffic_type_id
6263 self ._display_name = display_name
6364 self ._description = description
6465 self ._data_type = data_type
66+ self ._is_searchable = is_searchable
6567
6668 @property
6769 def id (self ):
@@ -83,6 +85,10 @@ def description(self):
8385 def data_type (self ):
8486 return self ._data_type
8587
88+ @property
89+ def is_searchable (self ):
90+ return self ._is_searchable
91+
8692 @classmethod
8793 def _build_single_from_collection_response (cls , client , response ):
8894 '''
@@ -93,12 +99,13 @@ def _build_single_from_collection_response(cls, client, response):
9399 response ['trafficTypeId' ],
94100 response ['displayName' ],
95101 response ['description' ],
96- response ['dataType' ]
102+ response ['dataType' ],
103+ response .get ('isSearchable' )
97104 )
98105
99106 @classmethod
100107 def create (cls , client , id , traffic_type_id , display_name , description ,
101- data_type ):
108+ data_type , is_searchable ):
102109 '''
103110 '''
104111 # TODO: Validate!
@@ -110,6 +117,7 @@ def create(cls, client, id, traffic_type_id, display_name, description,
110117 'trafficTypeId' : traffic_type_id ,
111118 'displayName' : display_name ,
112119 'description' : description ,
120+ 'isSearchable' : is_searchable ,
113121 'dataType' : None if data_type is None else data_type .upper ()
114122 },
115123 trafficTypeId = traffic_type_id
@@ -121,7 +129,8 @@ def create(cls, client, id, traffic_type_id, display_name, description,
121129 response ['trafficTypeId' ],
122130 response ['displayName' ],
123131 response ['description' ],
124- response ['dataType' ]
132+ response ['dataType' ],
133+ response .get ('isSearchable' )
125134 )
126135
127136 except HTTPResponseError as e :
0 commit comments