本文整理汇总了TypeScript中immutable-class.immutableArraysEqual函数的典型用法代码示例。如果您正苦于以下问题:TypeScript immutableArraysEqual函数的具体用法?TypeScript immutableArraysEqual怎么用?TypeScript immutableArraysEqual使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了immutableArraysEqual函数的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的TypeScript代码示例。
示例1: it
it('getGranularities appropriately for number', () => {
var defaults = getGranularities('number');
var expectedDefaults = [0.1, 1, 10, 100, 1000].map(granularityFromJS);
expect(immutableArraysEqual(defaults, expectedDefaults), 'number defaults are returned').to.equal(true);
var bucketedBy = getGranularities('number', granularityFromJS(100), false);
var expectedGrans = [100, 500, 1000, 5000, 10000].map(granularityFromJS);
expect(immutableArraysEqual(bucketedBy, expectedGrans), 'bucketed by returns larger granularities').to.equal(true);
});
示例2: equals
public equals(other: Customization): boolean {
return Customization.isCustomization(other) &&
this.title === other.title &&
this.headerBackground === other.headerBackground &&
this.customLogoSvg === other.customLogoSvg &&
immutableArraysEqual(this.externalViews, other.externalViews);
}
示例3: equals
public equals(other: Dimension): boolean {
return Dimension.isDimension(other) &&
this.name === other.name &&
this.title === other.title &&
this.expression.equals(other.expression) &&
this.kind === other.kind &&
this.url === other.url &&
immutableArraysEqual(this.granularities, other.granularities);
}
示例4: equals
public equals(other: Dimension): boolean {
return Dimension.isDimension(other) &&
this.name === other.name &&
this.title === other.title &&
this.formula === other.formula &&
this.kind === other.kind &&
this.url === other.url &&
immutableArraysEqual(this.granularities, other.granularities) &&
granularityEquals(this.bucketedBy, other.bucketedBy);
}
示例5: immutableArraysEqual
export function immutableListsEqual<T extends Equalable>(listA: List<T>, listB: List<T>): boolean {
if (listA === listB) return true;
if (!listA !== !listB) return false;
return immutableArraysEqual(listA.toArray(), listB.toArray());
}
示例6: equals
public equals(other: LinkViewConfig): boolean {
return LinkViewConfig.isLinkViewConfig(other) &&
this.title === other.title &&
immutableArraysEqual(this.linkItems, other.linkItems);
}