Struct ComplexTagCondition<TTagSet>
- Namespace
- Vintagestory.API.Datastructures
- Assembly
- VintagestoryAPI.dll
Holds a complex tag condition, either as a set of disjunctive entries ([a and b and c] or [d and e])
or as a set of conjunctive entries ([a or b or c] and [d or e]).
In both cases each of the inner sets can also have a set of forbidden tags that is always disjunctive.
The syntax for using these in json follows one simple rule: If no junction verb is specified, the group is treated as conjunctive (a and b and c)
["all", "of", "these"]
[["all", "of", "these"]]
[["all", "of", "these"], (or) { allOf: ["all", "of", "these"], noneOf: ["any", "of", "these"] }]
{ allOf: ["all", "of", "these"], noneOf: ["any", "of", "these"] }
{ anyOf: ["any", "of", "these"], noneOf: ["any", "of", "these"] }
{ anyOf: [["all", "of", "these"], { allOf: ["all", "of", "these"], noneOf: ["any", "of", "these"] }] }
{ allOf: [["anyOf", "of", "these"], (and) { anyOf: ["any", "of", "these"], noneOf: ["any", "of", "these"] }] }
[JsonConverter(typeof(GenericComplexConditionConverter))]
public struct ComplexTagCondition<TTagSet>
Type Parameters
TTagSet
- Inherited Members
- Extension Methods
Remarks
You cannot mix junction verbs on the same layer.
Fields
conditions
public ComplexTagCondition<TTagSet>.Condition[]? conditions
Field Value
isDisjunctive
public bool isDisjunctive
Field Value
Properties
IsEmpty
public readonly bool IsEmpty { get; }
Property Value
Methods
GetHashCode()
Returns the hash code for this instance.
public override readonly int GetHashCode()
Returns
- int
A 32-bit signed integer that is the hash code for this instance.