2 # Thierry Parmentelat - INRIA
6 from PLC.Method import Method
7 from PLC.Parameter import Parameter, Mixed
8 from PLC.Filter import Filter
9 from PLC.Auth import Auth
10 from PLC.NodeTagTypes import NodeTagType, NodeTagTypes
12 class GetNodeTagTypes(Method):
14 Returns an array of structs containing details about
17 The usual filtering scheme applies on this method.
20 roles = ['admin', 'pi', 'user', 'tech', 'node']
24 Mixed([Mixed(NodeTagType.fields['node_tag_type_id'],
25 NodeTagType.fields['name'])],
26 Filter(NodeTagType.fields)),
27 Parameter([str], "List of fields to return", nullok = True)
30 returns = [NodeTagType.fields]
32 def call(self, auth, node_tag_type_filter = None, return_fields = None):
33 return NodeTagTypes(self.api, node_tag_type_filter, return_fields)