cis data legacy resource model: resource filter

Specifies the filter criteria that each resource should satisfy in order to qualify for the final result set for a given query.

Representations:

{
    "composite_filter"{
        "filters"[
            {
                "composite_filter"{
                    "filters"[
                        {
                            "filter_type""TYPE",
                            "property_filter"{
                                "comparable_boolean"true,
                                "comparable_double"1.5,
                                "comparable_id"{
                                    "id""obj-103",
                                    "type""string"
                                },
                                "comparable_long"1,
                                "comparable_string""string",
                                "comparable_type""LONG",
                                "operator""EQUAL",
                                "property""string"
                            },
                            "resource_id"{
                                "id""obj-103",
                                "type""string"
                            },
                            "resource_type""string"
                        },
                        {
                            "filter_type""TYPE",
                            "property_filter"{
                                "comparable_boolean"true,
                                "comparable_double"1.5,
                                "comparable_id"{
                                    "id""obj-103",
                                    "type""string"
                                },
                                "comparable_long"1,
                                "comparable_string""string",
                                "comparable_type""LONG",
                                "operator""EQUAL",
                                "property""string"
                            },
                            "resource_id"{
                                "id""obj-103",
                                "type""string"
                            },
                            "resource_type""string"
                        }
                    ],
                    "operator""INTERSECT"
                },
                "filter_type""TYPE",
                "property_filter"{
                    "comparable_boolean"true,
                    "comparable_double"1.5,
                    "comparable_id"{
                        "id""obj-103",
                        "type""string"
                    },
                    "comparable_long"1,
                    "comparable_string""string",
                    "comparable_type""LONG",
                    "operator""EQUAL",
                    "property""string"
                },
                "resource_id"{
                    "id""obj-103",
                    "type""string"
                },
                "resource_type""string"
            },
            {
                "composite_filter"{
                    "filters"[
                        {
                            "filter_type""TYPE",
                            "property_filter"{
                                "comparable_boolean"true,
                                "comparable_double"1.5,
                                "comparable_id"{
                                    "id""obj-103",
                                    "type""string"
                                },
                                "comparable_long"1,
                                "comparable_string""string",
                                "comparable_type""LONG",
                                "operator""EQUAL",
                                "property""string"
                            },
                            "resource_id"{
                                "id""obj-103",
                                "type""string"
                            },
                            "resource_type""string"
                        },
                        {
                            "filter_type""TYPE",
                            "property_filter"{
                                "comparable_boolean"true,
                                "comparable_double"1.5,
                                "comparable_id"{
                                    "id""obj-103",
                                    "type""string"
                                },
                                "comparable_long"1,
                                "comparable_string""string",
                                "comparable_type""LONG",
                                "operator""EQUAL",
                                "property""string"
                            },
                            "resource_id"{
                                "id""obj-103",
                                "type""string"
                            },
                            "resource_type""string"
                        }
                    ],
                    "operator""INTERSECT"
                },
                "filter_type""TYPE",
                "property_filter"{
                    "comparable_boolean"true,
                    "comparable_double"1.5,
                    "comparable_id"{
                        "id""obj-103",
                        "type""string"
                    },
                    "comparable_long"1,
                    "comparable_string""string",
                    "comparable_type""LONG",
                    "operator""EQUAL",
                    "property""string"
                },
                "resource_id"{
                    "id""obj-103",
                    "type""string"
                },
                "resource_type""string"
            }
        ],
        "operator""INTERSECT"
    },
    "filter_type""TYPE",
    "property_filter"{
        "comparable_boolean"true,
        "comparable_double"1.5,
        "comparable_id"{
            "id""obj-103",
            "type""string"
        },
        "comparable_long"1,
        "comparable_string""string",
        "comparable_type""LONG",
        "operator""EQUAL",
        "property""string"
    },
    "resource_id"{
        "id""obj-103",
        "type""string"
    },
    "resource_type""string"
}
<?xml version="1.0" ?>
<ns0:ResourceFilter xmlns:ns0="http://vmware.com/cis/data/legacy/resource_model" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <resource_id>
    <id>obj-103</id>
    <type>string</type>
  </resource_id>
  <composite_filter>
    <filters-array>
      <array-item>
        <resource_id>
          <id>obj-103</id>
          <type>string</type>
        </resource_id>
        <composite_filter>
          <filters-array>
            <array-item>
              <resource_id>
                <id>obj-103</id>
                <type>string</type>
              </resource_id>
              <property_filter>
                <comparable_double>1.5</comparable_double>
                <comparable_string>string</comparable_string>
                <comparable_id>
                  <id>obj-103</id>
                  <type>string</type>
                </comparable_id>
                <comparable_boolean>true</comparable_boolean>
                <property>string</property>
                <comparable_type>LONG</comparable_type>
                <comparable_long>1</comparable_long>
                <operator>EQUAL</operator>
              </property_filter>
              <resource_type>string</resource_type>
              <filter_type>TYPE</filter_type>
            </array-item>
            <array-item>
              <resource_id>
                <id>obj-103</id>
                <type>string</type>
              </resource_id>
              <property_filter>
                <comparable_double>1.5</comparable_double>
                <comparable_string>string</comparable_string>
                <comparable_id>
                  <id>obj-103</id>
                  <type>string</type>
                </comparable_id>
                <comparable_boolean>true</comparable_boolean>
                <property>string</property>
                <comparable_type>LONG</comparable_type>
                <comparable_long>1</comparable_long>
                <operator>EQUAL</operator>
              </property_filter>
              <resource_type>string</resource_type>
              <filter_type>TYPE</filter_type>
            </array-item>
          </filters-array>
          <operator>INTERSECT</operator>
        </composite_filter>
        <property_filter>
          <comparable_double>1.5</comparable_double>
          <comparable_string>string</comparable_string>
          <comparable_id>
            <id>obj-103</id>
            <type>string</type>
          </comparable_id>
          <comparable_boolean>true</comparable_boolean>
          <property>string</property>
          <comparable_type>LONG</comparable_type>
          <comparable_long>1</comparable_long>
          <operator>EQUAL</operator>
        </property_filter>
        <resource_type>string</resource_type>
        <filter_type>TYPE</filter_type>
      </array-item>
      <array-item>
        <resource_id>
          <id>obj-103</id>
          <type>string</type>
        </resource_id>
        <composite_filter>
          <filters-array>
            <array-item>
              <resource_id>
                <id>obj-103</id>
                <type>string</type>
              </resource_id>
              <property_filter>
                <comparable_double>1.5</comparable_double>
                <comparable_string>string</comparable_string>
                <comparable_id>
                  <id>obj-103</id>
                  <type>string</type>
                </comparable_id>
                <comparable_boolean>true</comparable_boolean>
                <property>string</property>
                <comparable_type>LONG</comparable_type>
                <comparable_long>1</comparable_long>
                <operator>EQUAL</operator>
              </property_filter>
              <resource_type>string</resource_type>
              <filter_type>TYPE</filter_type>
            </array-item>
            <array-item>
              <resource_id>
                <id>obj-103</id>
                <type>string</type>
              </resource_id>
              <property_filter>
                <comparable_double>1.5</comparable_double>
                <comparable_string>string</comparable_string>
                <comparable_id>
                  <id>obj-103</id>
                  <type>string</type>
                </comparable_id>
                <comparable_boolean>true</comparable_boolean>
                <property>string</property>
                <comparable_type>LONG</comparable_type>
                <comparable_long>1</comparable_long>
                <operator>EQUAL</operator>
              </property_filter>
              <resource_type>string</resource_type>
              <filter_type>TYPE</filter_type>
            </array-item>
          </filters-array>
          <operator>INTERSECT</operator>
        </composite_filter>
        <property_filter>
          <comparable_double>1.5</comparable_double>
          <comparable_string>string</comparable_string>
          <comparable_id>
            <id>obj-103</id>
            <type>string</type>
          </comparable_id>
          <comparable_boolean>true</comparable_boolean>
          <property>string</property>
          <comparable_type>LONG</comparable_type>
          <comparable_long>1</comparable_long>
          <operator>EQUAL</operator>
        </property_filter>
        <resource_type>string</resource_type>
        <filter_type>TYPE</filter_type>
      </array-item>
    </filters-array>
    <operator>INTERSECT</operator>
  </composite_filter>
  <property_filter>
    <comparable_double>1.5</comparable_double>
    <comparable_string>string</comparable_string>
    <comparable_id>
      <id>obj-103</id>
      <type>string</type>
    </comparable_id>
    <comparable_boolean>true</comparable_boolean>
    <property>string</property>
    <comparable_type>LONG</comparable_type>
    <comparable_long>1</comparable_long>
    <operator>EQUAL</operator>
  </property_filter>
  <resource_type>string</resource_type>
  <filter_type>TYPE</filter_type>
</ns0:ResourceFilter>

Attributes:

Name Type Description
Required
filter_type string The type of the filter used.

The types of filters used to restrict the resources returned from a query. Value is one of:
TYPE: Filter by resource type.
ID: Filter by resource identifier.
PROPERTY: Filter by condition on a resource model property value.
COMPOSITE: A composition of multiple filters.

Optional
resource_type string Limits the results returned for a query to resources with the specified resource type, e.g. com.acme.Person. TODO: Add reference to the documentation/API that clients can check in order to find out what types and properties they can query.

Optional. It is only relevant when filter_type has value TYPE. This field is optional and it is only relevant when the value of filter_type is TYPE.

resource_id typed_ID The identifier of an individual resource that satisfies this filter criteria.

Optional. It is only relevant when filter_type has value ID. This field is optional and it is only relevant when the value of filter_type is ID.

property_filter property_filter Filters the resource set by evaluating conditions (predicates) on their own or related resource model properties.

For instance, it could be used to match all com.acme.Person resources which have property name starting with John or property gender equal to male.

Optional. It is only relevant when filter_type has value PROPERTY. This field is optional and it is only relevant when the value of filter_type is PROPERTY.

composite_filter composite_filter Filters the resource set by evaluating a composition of multiple resource filters. Provides ability to build arbitrary trees of resource filter nodes and control their precedence.

Optional. It is only relevant when filter_type has value COMPOSITE. This field is optional and it is only relevant when the value of filter_type is COMPOSITE.