OpenCores
URL https://opencores.org/ocsvn/leros/leros/trunk

Subversion Repositories leros

[/] [leros/] [trunk/] [java/] [target/] [src/] [java/] [lang/] [Object.java] - Blame information for rev 4

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 3 martin
/*
2
   Copyright 2011 Martin Schoeberl <masca@imm.dtu.dk>,
3
                  Technical University of Denmark, DTU Informatics.
4
   All rights reserved.
5
 
6
   Redistribution and use in source and binary forms, with or without
7
   modification, are permitted provided that the following conditions are met:
8
 
9
      1. Redistributions of source code must retain the above copyright notice,
10
         this list of conditions and the following disclaimer.
11
 
12
      2. Redistributions in binary form must reproduce the above copyright
13
         notice, this list of conditions and the following disclaimer in the
14
         documentation and/or other materials provided with the distribution.
15
 
16
   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER ``AS IS'' AND ANY EXPRESS
17
   OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
18
   OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
19
   NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY
20
   DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21
   (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22
   LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23
   ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24
   (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
25
   THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26
 
27
   The views and conclusions contained in the software and documentation are
28
   those of the authors and should not be interpreted as representing official
29
   policies, either expressed or implied, of the copyright holder.
30
 */
31
 
32 4 martin
package java.lang;
33 3 martin
 
34 4 martin
// import com.muvium.leros.Native;
35 3 martin
 
36
/**
37 4 martin
 * Part of the VERY minimalistic Leros/muvium JDK
38 3 martin
 *
39 4 martin
 * @author Martin Schoeberl
40 3 martin
 *
41
 */
42 4 martin
public class Object {
43 3 martin
 
44 4 martin
        public Object() {
45
        }
46 3 martin
 
47 4 martin
        public boolean equals(Object o) {
48
                return this == o;
49
        }
50 3 martin
 
51 4 martin
        public int hashCode() {
52
                // MS: we should just use the address as default implementation
53
                // return Native.toInt(this);
54
                return 0;
55 3 martin
        }
56
 
57
 
58 4 martin
        public String toString() {
59
                // return "Object " + hashCode();
60
                // no strings yet
61
                return null;
62 3 martin
        }
63 4 martin
 
64
        /*
65
         * protected void finalize() throws Throwable { }
66
         */
67
 
68
 
69
//      protected Object clone() throws CloneNotSupportedException {
70
//              throw new CloneNotSupportedException("Object not cloneable");
71
//      }
72
 
73
        protected Object clone() {
74
                return null;
75
        }
76
 
77
//      public final Class getClass() {
78
//              throw new Error("getClass() NYI");
79
//      }
80
 
81
//      public final void notify() throws IllegalMonitorStateException {
82
//              ; // fake
83
//      }
84
//
85
//
86
//      public final void notifyAll() throws IllegalMonitorStateException {
87
//              ; // fake
88
//      }
89
//
90
//
91
//      public final void wait() throws IllegalMonitorStateException,
92
//                      InterruptedException {
93
//              ; // fake
94
//      }
95
 
96
        /*
97
         * public final void wait(long ms) throws IllegalMonitorStateException,
98
         * InterruptedException { wait(ms, 0); }
99
         */
100
 
101 3 martin
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.