@staticmethod
def construct_qos_policy_info(context, id, qos_policy, action):
    """
        #    {u'policy': {
        #               'shared': False,
        #               'tenant_id': u'c414cf57e9fc49efb8e3e0c8d4e41b33',
        #                u'name': u'qos-policy',
        #               'description': '',
        #               'rules':[],
        #               'id' :'5720800f-dece-4c9a-93d4-5dc3ef94ccb7'}}
        """
    if action == 'UPDATE':
        qos_policy = qos_policy['policy']
    qos_policy_info = {'input': {'id': id if id != 0 else qos_policy['id']}}
    input = qos_policy_info['input']
    if 'type' in qos_policy:
        input['type'] = qos_policy['type']
    if 'description' in qos_policy:
        input['description'] = qos_policy['description']
    if 'tenant_id' in qos_policy:
        input['tenant_id'] = qos_policy['tenant_id']
    if 'shared' in qos_policy:
        input['shared'] = qos_policy['shared']
    if 'name' in qos_policy:
        input['name'] = qos_policy['name']
    return qos_policy_info
