source: java/main/src/main/java/com/framsticks/params/OpaqueObject.java @ 107

Last change on this file since 107 was 107, checked in by psniegowski, 11 years ago

HIGHLIGHTS:

  • add SimultorProviders? hierarchy
  • start Framsticks server over SSH
  • FJF compatible with Framsticks 4.0rc3
  • reading and writing of standard.expt
  • a proof-of-concept implementation of StandardExperiment?

CHANGELOG:
Optionally return FreeAccess? from registry.

Add SimulatorRange?.

StandardExperiment? with genotypes circulation.

Automate registration around StandardState?.

More improvements to StandardExperiment?.

Skeleton version of StandardExperiment?.

Test saving of StandardState?.

Standard experiment state is being loaded.

More development towards StandardState? reading.

Work on reading standard experiment state.

Add classes for standard experiment.

Update example standard.expt

Add FreeAccess? and FreeObject?.

Made compatible with version 4.0rc3

Change deserialization policy.

Improve SSH support.

Working running simulator over SSH.

Fix joining bug in Experiment.

Working version of SimulatorRunner?.

Add more SimulatorProviders?.

Working PrimeExperimentTest? with 4.0rc3

Add references to deserialization.

Add OpaqueObject? and it's serialization.

Add deserialization of dictionaries.

Partial implementation of deserialization.

Add more tests for deserialization.

Prepare tests for deserialization.

Add proper result to prime experiment test.

Minor fixes to simulators providers.

Draft version of SimulatorProvider?.

Add SimulatorProvider? interface.

File size: 906 bytes
Line 
1package com.framsticks.params;
2
3public class OpaqueObject {
4
5        protected final String typeName;
6        protected final long address;
7
8        /**
9         * @param typeName
10         * @param address
11         */
12        public OpaqueObject(String typeName, long address) {
13                this.typeName = typeName;
14                this.address = address;
15        }
16
17        @Override
18        public String toString() {
19                return typeName + "<0x" + Long.toHexString(address) + ">";
20        }
21
22        /**
23         * @return the typeName
24         */
25        public String getTypeName() {
26                return typeName;
27        }
28
29        /**
30         * @return the address
31         */
32        public long getAddress() {
33                return address;
34        }
35
36        @Override
37        public boolean equals(Object obj) {
38                if (!(obj instanceof OpaqueObject)) {
39                        return false;
40                }
41                OpaqueObject opaque = (OpaqueObject) obj;
42                return typeName.equals(opaque.getTypeName()) && address == opaque.getAddress();
43        }
44
45        @Override
46        public int hashCode() {
47                return typeName.hashCode() ^ new Long(address).hashCode();
48        }
49}
Note: See TracBrowser for help on using the repository browser.