Class for creating a facets argument, used for check-box navigation. It also has support
for parsing and toggling facet values, so it can be used to keep track of selection changes.
Note that Facets are immutable and all methods return new Facets objects.
Inheritance Hierarchy
Apptus.ESales.ConnectorFacets
Namespace: Apptus.ESales.Connector
Assembly: Apptus.Esales.ConnectorApi (in Apptus.Esales.ConnectorApi.dll) Version: 3.47.3
Syntax
C#
public class Facets
The Facets type exposes the following members.
Constructors
Name | Description | |
---|---|---|
![]() | Facets |
Create a new empty Facets.
|
![]() | Facets(String, IEnumerableString) |
Create a new Facets with the given attribute and values.
|
![]() | Facets(String, String) |
Create a new Facets with the given attribute and values.
|
Methods
Name | Description | |
---|---|---|
![]() | Add(String, IEnumerableString) |
Return a new Facets with the given attribute and values added.
|
![]() | Add(String, String) |
Return a new Facets with the given attribute and values added.
|
![]() | AddRange |
Return a new Facets with the given attribute range added. If a range of the
current attribute already existed, it will replace the existing one. Note that
facet ranges are inclusive.
|
![]() | Equals | (Overrides ObjectEquals(Object).) |
![]() | Finalize | (Inherited from Object.) |
![]() | GetHashCode | (Overrides ObjectGetHashCode.) |
![]() | GetType | (Inherited from Object.) |
![]() | MemberwiseClone | (Inherited from Object.) |
![]() ![]() | Parse |
Create a Facets object from the source string.
|
![]() | Remove |
Return a new Facets with the given attribute removed.
|
![]() | Toggle |
Toggle the given attribute and value.
|
![]() | ToString |
Builds and returns a string on the facet argument format.
(Overrides ObjectToString.) |
Examples
Facets f = new Facets("color", "yellow", "blue").Add("brand", "nike"); // f.ToString() is: brand:nike,color:blue|yellow ArgMap panelArguments = new ArgMap(); panelArguments.Add("facets", f); // ... other arguments...
ToString()
Facets f = Facets.Parse(facetsString);
f = f.Toggle(clickedAttribute, clickedValue); panelArguments.Add("facets", f); // ... add other arguments and send request...
See Also