~mahara-contributors/mahara-adminlang/adminlang-master

« back to all changes in this revision

Viewing changes to htdocs/lib/flowplayer/lib/corelib/src/com/adobe/utils/DictionaryUtil.as

  • Committer: Ruslan Kabalin
  • Date: 2011-08-03 14:54:09 UTC
  • Revision ID: git-v1:a3409b53a971ec3bad8b5d1329298046d9596381
Revert back to master brach.

The adminlang-master was mistakingly based on the mahara 1.3_STABLE. This is
required for easy merge with the master.

Command used:
for i in `git rev-list
f731cf9b2cf72b61ed6a317acab23a30b9046c8a..afb5850ba246f41b624c162e8d8e6e72c534f239`;
do git revert -n $i; done

Change-Id: I9db8553a66facfaca81492cd978f974c6e7b8892

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
        Adobe Systems Incorporated(r) Source Code License Agreement
 
3
        Copyright(c) 2005 Adobe Systems Incorporated. All rights reserved.
 
4
        
 
5
        Please read this Source Code License Agreement carefully before using
 
6
        the source code.
 
7
        
 
8
        Adobe Systems Incorporated grants to you a perpetual, worldwide, non-exclusive, 
 
9
        no-charge, royalty-free, irrevocable copyright license, to reproduce,
 
10
        prepare derivative works of, publicly display, publicly perform, and
 
11
        distribute this source code and such derivative works in source or 
 
12
        object code form without any attribution requirements.  
 
13
        
 
14
        The name "Adobe Systems Incorporated" must not be used to endorse or promote products
 
15
        derived from the source code without prior written permission.
 
16
        
 
17
        You agree to indemnify, hold harmless and defend Adobe Systems Incorporated from and
 
18
        against any loss, damage, claims or lawsuits, including attorney's 
 
19
        fees that arise or result from your use or distribution of the source 
 
20
        code.
 
21
        
 
22
        THIS SOURCE CODE IS PROVIDED "AS IS" AND "WITH ALL FAULTS", WITHOUT 
 
23
        ANY TECHNICAL SUPPORT OR ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING,
 
24
        BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
 
25
        FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  ALSO, THERE IS NO WARRANTY OF 
 
26
        NON-INFRINGEMENT, TITLE OR QUIET ENJOYMENT.  IN NO EVENT SHALL MACROMEDIA
 
27
        OR ITS SUPPLIERS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
 
28
        EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 
 
29
        PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
 
30
        OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
 
31
        WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 
 
32
        OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOURCE CODE, EVEN IF
 
33
        ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
34
*/
 
35
 
 
36
package com.adobe.utils
 
37
{
 
38
        import flash.utils.Dictionary;
 
39
        
 
40
        public class DictionaryUtil
 
41
        {
 
42
                
 
43
                /**
 
44
                *       Returns an Array of all keys within the specified dictionary.   
 
45
                * 
 
46
                *       @param d The Dictionary instance whose keys will be returned.
 
47
                * 
 
48
                *       @return Array of keys contained within the Dictionary
 
49
                *
 
50
                *       @langversion ActionScript 3.0
 
51
                *       @playerversion Flash 9.0
 
52
                *       @tiptext
 
53
                */                                      
 
54
                public static function getKeys(d:Dictionary):Array
 
55
                {
 
56
                        var a:Array = new Array();
 
57
                        
 
58
                        for (var key:Object in d)
 
59
                        {
 
60
                                a.push(key);
 
61
                        }
 
62
                        
 
63
                        return a;
 
64
                }
 
65
                
 
66
                /**
 
67
                *       Returns an Array of all values within the specified dictionary.         
 
68
                * 
 
69
                *       @param d The Dictionary instance whose values will be returned.
 
70
                * 
 
71
                *       @return Array of values contained within the Dictionary
 
72
                *
 
73
                *       @langversion ActionScript 3.0
 
74
                *       @playerversion Flash 9.0
 
75
                *       @tiptext
 
76
                */                                      
 
77
                public static function getValues(d:Dictionary):Array
 
78
                {
 
79
                        var a:Array = new Array();
 
80
                        
 
81
                        for each (var value:Object in d)
 
82
                        {
 
83
                                a.push(value);
 
84
                        }
 
85
                        
 
86
                        return a;
 
87
                }
 
88
                
 
89
        }
 
90
}
 
 
b'\\ No newline at end of file'