Create a Variable Attributes Query node.


Namespace: NetricsServerInterface
Assembly: NetricsServerInterface (in NetricsServerInterface.dll)

Syntax

Visual Basic (Declaration)
Public Shared Function Attributes( _ 
   ByVal attr_values As String(),  _ 
   ByVal attr_names As String(),  _ 
   ByVal attr_weights As Double() _ 
) As NetricsQuery
C#
public static NetricsQuery Attributes(
   string[] attr_values,
   string[] attr_names,
   double[] attr_weights
)
C++
public:
 static NetricsQuery Attributes(
   array<String>^ attr_values,
   array<String>^ attr_names,
   array<double>^ attr_weights
)
J#
public static NetricsQuery Attributes(
   string[] attr_values,
   string[] attr_names,
   double[] attr_weights
)
JScript
public static  function Attributes(
   attr_values : String[],
   attr_names : String[],
   attr_weights : double[]
) : NetricsQuery

Parameters

attr_values
the list of attribute values to be matched.
attr_names
the list of names of the attribute to be matched. This must correspond to the attr_values.
attr_weights
the list of weighting factors for each attribute. This may be null, in which case all attributes get equal weights. If given this must match the attr_values and attr_names arrays.

Return Value

A new NetricsQuery object for this query.

Remarks

This is used to query a set of Variable Attribute values. It is equivalent to an And of a set of simple queries on the attribute values with an empty score of -1.0 and an ignore scores of -1.0 on the And. That is it is an And of a match on each of the listed attributes where missing attribute values in the record are ignored.

The same options excepted by a Simple query can be applied to this query. That includes using a thesaurus, which will apply to all attributes, and setting the empty score. Note that by setting the empty score to something other than -1.0 the default behavior of ignoring missing attribute values can be changed so that missing values will lower the overall score rather than being ignored.

The attr_weights argument allows a weight factor to be applied to each of the attributes. This behaves as the querylet weights do in the And query, it adjusts the relative importance of a particular attribute value but it does not reduce the final score.

See Also