UNPKG

yimultiscreenserver-sdk-web

Version:

YiMultiScreenServer SDK for Web

38 lines (30 loc) 1.07 kB
import { AccountBindDeviceVO } from "../../../vo/account/AccountBindDeviceVO"; export class AccountBindDeviceResponse { boundDisplayDevices: AccountBindDeviceVO[]; constructor() { this.boundDisplayDevices = []; } equals(o: any): boolean { return o instanceof AccountBindDeviceResponse && this.arraysEqual(this.boundDisplayDevices, o.boundDisplayDevices); } toString(): string { return `AccountBindDeviceResponse{` + `boundDisplayDevices=${this.boundDisplayDevices.map(c => c.toString()).join(", ")}, ` + `}`; } private arraysEqual<T>(a: T[], b: T[]): boolean { // 首先检查数组长度 if (a.length !== b.length) { return false; } // 检查每个元素是否相等 for (let i = 0; i < a.length; i++) { if (a[i] !== b[i]) { return false; } } // 如果所有元素都相等,那么数组相等 return true; } }