/js/lib/Socket.IO-node/support/socket.io-client/lib/vendor/web-socket-js/flash-src/com/hurlant/util/ArrayUtil.as
ActionScript | 25 lines | 13 code | 4 blank | 8 comment | 4 complexity | d764ee34d244f1dedca16b5741648097 MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.1, MPL-2.0-no-copyleft-exception, BSD-3-Clause
- /**
- * ArrayUtil
- *
- * A class that allows to compare two ByteArrays.
- * Copyright (c) 2007 Henri Torgemane
- *
- * See LICENSE.txt for full license information.
- */
- package com.hurlant.util {
- import flash.utils.ByteArray;
-
-
- public class ArrayUtil {
-
- public static function equals(a1:ByteArray, a2:ByteArray):Boolean {
- if (a1.length != a2.length) return false;
- var l:int = a1.length;
- for (var i:int=0;i<l;i++) {
- if (a1[i]!=a2[i]) return false;
- }
- return true;
- }
- }
-
- }