Skip to content

Commit

Permalink
Review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
SWH-Relewise committed Dec 5, 2024
1 parent f54fd3c commit cd73be0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { ContentHighlightProps, ContentSearchSettingsHighlightSettings, HighlightSettings2ContentContentHighlightPropsHighlightSettings2Limits, HighlightSettings2ContentContentHighlightPropsHighlightSettings2ResponseShape } from '../../models/data-contracts';

export class ContentHighlightingBuilder {
private enabled: boolean = true;
private enabledState: boolean = true;
private highlightable: ContentHighlightProps = {
$type: 'Relewise.Client.Requests.Shared.Highlighting.ContentHighlightProps, Relewise.Client',
displayName: false
Expand All @@ -11,8 +11,8 @@ export class ContentHighlightingBuilder {
includeOffsets: false
};

public enable(enabled: boolean): this {
this.enabled = enabled;
public enabled(enabled: boolean): this {
this.enabledState = enabled;

return this;
}
Expand Down Expand Up @@ -41,10 +41,10 @@ export class ContentHighlightingBuilder {
public build(): ContentSearchSettingsHighlightSettings {
return {
$type: 'Relewise.Client.Requests.Search.Settings.ContentSearchSettings+HighlightSettings, Relewise.Client',
enabled: this.enabled,
enabled: this.enabledState,
highlightable: this.highlightable,
limit: this.limit,
shape: this.shape
} as ContentSearchSettingsHighlightSettings;
};
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { HighlightSettings2ProductProductHighlightPropsHighlightSettings2Limits, HighlightSettings2ProductProductHighlightPropsHighlightSettings2ResponseShape, ProductHighlightProps, ProductSearchSettingsHighlightSettings } from '../../models/data-contracts';

export class ProductHighlightingBuilder {
private enabled: boolean = true;
private enabledState: boolean = true;
private highlightable: ProductHighlightProps = {
$type: 'Relewise.Client.Requests.Shared.Highlighting.ProductHighlightProps, Relewise.Client',
displayName: false
Expand All @@ -11,8 +11,8 @@ export class ProductHighlightingBuilder {
includeOffsets: false
};

public enable(enabled: boolean): this {
this.enabled = enabled;
public enabled(enabled: boolean): this {
this.enabledState = enabled;

return this;
}
Expand Down Expand Up @@ -41,10 +41,10 @@ export class ProductHighlightingBuilder {
public build(): ProductSearchSettingsHighlightSettings {
return {
$type: 'Relewise.Client.Requests.Search.Settings.ProductSearchSettings+HighlightSettings, Relewise.Client',
enabled: this.enabled,
enabled: this.enabledState,
highlightable: this.highlightable,
limit: this.limit,
shape: this.shape
} as ProductSearchSettingsHighlightSettings;
};
}
}

0 comments on commit cd73be0

Please sign in to comment.