in source/packages/libraries/clients/assetlibrary-client/src/client/search.model.ts [121:201]
public toHttpQueryString(): string {
let qs: string[] = [];
if (this.types) {
this.types.forEach((k) => qs.push(`type=${k}`));
}
if (this.ntypes) {
this.ntypes.forEach((k) => qs.push(`ntype=${k}`));
}
if (this.ancestorPath) {
qs.push(`ancestorPath=${this.ancestorPath}`);
}
if (this.includeAncestor) {
qs.push(`includeAncestor=${this.includeAncestor}`);
}
if (this.eq) {
qs = qs.concat(this.buildQSValues('eq', this.eq, true));
}
if (this.neq) {
qs = qs.concat(this.buildQSValues('neq', this.neq, true));
}
if (this.lt) {
qs = qs.concat(this.buildQSValues('lt', this.lt, true));
}
if (this.lte) {
qs = qs.concat(this.buildQSValues('lte', this.lte, true));
}
if (this.gt) {
qs = qs.concat(this.buildQSValues('gt', this.gt, true));
}
if (this.gte) {
qs = qs.concat(this.buildQSValues('gte', this.gte, true));
}
if (this.startsWith) {
qs = qs.concat(this.buildQSValues('startsWith', this.startsWith, true));
}
if (this.endsWith) {
qs = qs.concat(this.buildQSValues('endsWith', this.endsWith, true));
}
if (this.contains) {
qs = qs.concat(this.buildQSValues('contains', this.contains, true));
}
if (this.exist) {
qs = qs.concat(this.buildQSValues('exist', this.exist, true));
}
if (this.nexist) {
qs = qs.concat(this.buildQSValues('nexist', this.nexist, true));
}
if (this.summarize) {
qs.push(`summarize=${this.summarize}`);
}
if (this.facetField) {
const path = this.traversalPathToQSValue(
this.facetField.field,
this.facetField.traversals
);
qs.push(`facetField=${encodeURIComponent(path)}`);
}
if (this.sort) {
qs.push(`sort=${this.sort}`);
}
return qs.join('&');
}