Last change
on this file since 193 was
193,
checked in by Maciej Komosinski, 10 years ago
|
Set svn:eol-style native for all textual files
|
-
Property svn:eol-style set to
native
|
File size:
818 bytes
|
Rev | Line | |
---|
[107] | 1 | package com.framsticks.experiment; |
---|
| 2 | |
---|
| 3 | import com.framsticks.communication.Address; |
---|
| 4 | import com.framsticks.params.annotations.ParamAnnotation; |
---|
| 5 | import com.framsticks.util.dispatching.AbstractJoinable; |
---|
| 6 | import com.framsticks.util.lang.Strings; |
---|
| 7 | |
---|
| 8 | public abstract class SingleSimulatorProvider extends AbstractJoinable implements SimulatorProvider { |
---|
| 9 | |
---|
| 10 | |
---|
| 11 | @ParamAnnotation(id = "address") |
---|
| 12 | public void setAddressString(String address) { |
---|
| 13 | setAddress(new Address(address)); |
---|
| 14 | } |
---|
| 15 | |
---|
| 16 | @ParamAnnotation(id = "address") |
---|
| 17 | public String getAddressString() { |
---|
| 18 | return Strings.toStringNullProof(getAddress(), ""); |
---|
| 19 | } |
---|
| 20 | |
---|
| 21 | public abstract void setAddress(Address address); |
---|
| 22 | |
---|
| 23 | public abstract Address getAddress(); |
---|
| 24 | |
---|
| 25 | @Override |
---|
| 26 | public String toString() { |
---|
| 27 | return "simulator connector to: " + Strings.toStringNullProof(getAddress(), "<null>"); |
---|
| 28 | } |
---|
| 29 | |
---|
| 30 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.