Menu

[r513]: / phprpc_3.0 / dotNET / ArrayList.cs  Maximize  Restore  History

Download this file

60 lines (57 with data), 2.5 kB

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
/**********************************************************\
| |
| The implementation of PHPRPC Protocol 3.0 |
| |
| ArrayList.cs |
| |
| Release 3.0.1 |
| Copyright (c) 2005-2008 by Team-PHPRPC |
| |
| WebSite: http://www.phprpc.org/ |
| http://www.phprpc.net/ |
| http://www.phprpc.com/ |
| http://sourceforge.net/projects/php-rpc/ |
| |
| Authors: Ma Bingyao <andot@ujn.edu.cn> |
| |
| This file may be distributed and/or modified under the |
| terms of the GNU Lesser General Public License (LGPL) |
| version 3.0 as published by the Free Software Foundation |
| and appearing in the included file LICENSE. |
| |
\**********************************************************/
/* ArrayList class.
*
* Copyright (C) 2005-2008 Ma Bingyao <andot@ujn.edu.cn>
* Version: 3.0
* LastModified: Dec 18, 2008
* This library is free. You can redistribute it and/or modify it.
*/
#if SILVERLIGHT
namespace System.Collections {
using System;
public class ArrayList: System.Collections.Generic.List<Object> {
private Object syncRoot = new Object();
public ArrayList() : base() {
}
public ArrayList(Int32 capacity) : base(capacity) {
}
public ArrayList(ICollection collection) : base((System.Collections.Generic.IEnumerable<Object>)collection) {
}
public new int Add(Object item) {
base.Add(item);
return base.Count - 1;
}
public Array ToArray(Type type) {
Array result = Array.CreateInstance(type, Count);
base.ToArray().CopyTo(result, 0);
return result;
}
public virtual Object SyncRoot {
get {
return syncRoot;
}
}
}
}
#endif
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.