~ubuntu-branches/ubuntu/trusty/emscripten/trusty-proposed

« back to all changes in this revision

Viewing changes to third_party/websockify/include/web-socket-js/src/flash-src/third-party/com/hurlant/util/ArrayUtil.as

  • Committer: Package Import Robot
  • Author(s): Sylvestre Ledru
  • Date: 2014-01-19 14:12:40 UTC
  • mfrom: (1.2.4)
  • Revision ID: package-import@ubuntu.com-20140119141240-jg1l42cc158j59tn
Tags: 1.9.0~20140119~7dc8c2f-1
* New snapshot release (Closes: #733714)
* Provide sources for javascript and flash. Done in orig-tar.sh
  Available in third_party/websockify/include/web-socket-js/src/
  (Closes: #735903)

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/**
 
2
 * ArrayUtil
 
3
 * 
 
4
 * A class that allows to compare two ByteArrays.
 
5
 * Copyright (c) 2007 Henri Torgemane
 
6
 * 
 
7
 * See LICENSE.txt for full license information.
 
8
 */
 
9
package com.hurlant.util {
 
10
        import flash.utils.ByteArray;
 
11
        
 
12
        
 
13
        public class ArrayUtil {
 
14
                
 
15
                public static function equals(a1:ByteArray, a2:ByteArray):Boolean {
 
16
                        if (a1.length != a2.length) return false;
 
17
                        var l:int = a1.length;
 
18
                        for (var i:int=0;i<l;i++) {
 
19
                                if (a1[i]!=a2[i]) return false;
 
20
                        }
 
21
                        return true;
 
22
                }
 
23
        }
 
24
        
 
25
}
 
 
b'\\ No newline at end of file'