Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Instrument Control
NomadCommandSystem
Commits
633691b0
Commit
633691b0
authored
Feb 27, 2017
by
yannick legoc
Browse files
Replaced AtomicCommandBox accessor class with responder.
parent
8344c033
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
src/main/java/fr/ill/ics/core/property/BooleanProperty.java
View file @
633691b0
...
...
@@ -18,7 +18,7 @@
package
fr.ill.ics.core.property
;
import
fr.ill.ics.nscclient.command.
Atomic
CommandBoxAccessor
Proxy
;
import
fr.ill.ics.nscclient.command.CommandBoxAccessor
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
public
class
BooleanProperty
extends
Property
{
...
...
@@ -33,7 +33,7 @@ public class BooleanProperty extends Property {
public
String
getServerValue
()
{
// Don't use format for the moment. The value can only be "true" or "false"
if
(
isCommandBox
)
{
return
Boolean
.
toString
(
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
getBooleanValue
(
containerId
,
id
));
return
Boolean
.
toString
(
CommandBoxAccessor
.
getInstance
(
serverId
).
getBooleanValue
(
containerId
,
id
));
}
else
{
return
Boolean
.
toString
(
DataAccessor
.
getInstance
(
serverId
).
getBooleanValue
(
containerId
,
id
));
}
...
...
@@ -44,7 +44,7 @@ public class BooleanProperty extends Property {
//try {
boolean
ok
=
true
;
if
(
isCommandBox
)
{
ok
=
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
setBooleanValue
(
containerId
,
id
,
Boolean
.
valueOf
(
value
).
booleanValue
());
ok
=
CommandBoxAccessor
.
getInstance
(
serverId
).
setBooleanValue
(
containerId
,
id
,
Boolean
.
valueOf
(
value
).
booleanValue
());
}
else
{
ok
=
DataAccessor
.
getInstance
(
serverId
).
setBooleanValue
(
containerId
,
id
,
Boolean
.
valueOf
(
value
).
booleanValue
());
if
(!
ok
)
{
...
...
src/main/java/fr/ill/ics/core/property/Float32ArrayProperty.java
deleted
100644 → 0
View file @
8344c033
/*
* Nomad Instrument Control Software
*
* Copyright 2011 Institut Laue-Langevin
*
* Licensed under the EUPL, Version 1.1 only (the "License");
* You may not use this work except in compliance with the Licence.
* You may obtain a copy of the Licence at:
*
* http://joinup.ec.europa.eu/software/page/eupl
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the Licence is distributed on an "AS IS" basis,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the Licence for the specific language governing permissions and
* limitations under the Licence.
*/
package
fr.ill.ics.core.property
;
import
fr.ill.ics.core.property.array.Array
;
import
fr.ill.ics.core.property.array.Float32Array
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
public
class
Float32ArrayProperty
extends
FloatArrayProperty
{
Float32Array
float32Array
=
new
Float32Array
();
public
Float32ArrayProperty
(
int
containerId
,
int
id
,
boolean
isCommandBox
)
{
super
(
containerId
,
id
,
isCommandBox
);
getServerArray
();
// must be left here
}
public
Array
getServerArray
()
{
if
(
isCommandBox
)
{
//int databaseId = AtomicCommandBoxAccessorProxy.getInstance(serverId).getDatabaseID(containerId);
float32Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getFloat32Array
(
getDatabaseID
(),
id
));
}
else
{
float32Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getFloat32Array
(
containerId
,
id
));
}
arraySize
=
float32Array
.
getSize
();
return
float32Array
;
}
public
Array
getCurrentArray
()
{
return
float32Array
;
}
public
void
setServerArray
(
Array
array
)
{
if
(
isCommandBox
)
{
//int databaseId = AtomicCommandBoxAccessorProxy.getInstance(serverId).getDatabaseID(containerId);
DataAccessor
.
getInstance
(
serverId
).
setFloat32Array
(
getDatabaseID
(),
id
,
float32Array
.
getArray
());
}
else
{
DataAccessor
.
getInstance
(
serverId
).
setFloat32Array
(
containerId
,
id
,
float32Array
.
getArray
());
}
}
public
float
getMinValue
()
{
return
float32Array
.
getMinValue
();
}
public
float
getMaxValue
()
{
return
float32Array
.
getMaxValue
();
}
public
String
getType
()
{
return
"float32array"
;
}
}
\ No newline at end of file
src/main/java/fr/ill/ics/core/property/Float32Property.java
deleted
100644 → 0
View file @
8344c033
/*
* Nomad Instrument Control Software
*
* Copyright 2011 Institut Laue-Langevin
*
* Licensed under the EUPL, Version 1.1 only (the "License");
* You may not use this work except in compliance with the Licence.
* You may obtain a copy of the Licence at:
*
* http://joinup.ec.europa.eu/software/page/eupl
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the Licence is distributed on an "AS IS" basis,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the Licence for the specific language governing permissions and
* limitations under the Licence.
*/
package
fr.ill.ics.core.property
;
import
fr.ill.ics.nscclient.command.AtomicCommandBoxAccessorProxy
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
import
fr.ill.ics.util.ConfigManager
;
public
class
Float32Property
extends
FloatProperty
{
public
Float32Property
(
int
containerId
,
int
id
,
boolean
isCommandBox
)
{
super
(
containerId
,
id
,
isCommandBox
);
}
public
String
getServerValue
()
{
if
(
isCommandBox
)
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Float
(
AtomicCommandBoxAccessorProxy
.
getInstance
(
serverId
).
getFloat32Value
(
containerId
,
id
)).
toString
());
}
else
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Float
(
DataAccessor
.
getInstance
(
serverId
).
getFloat32Value
(
containerId
,
id
)).
toString
());
}
}
public
boolean
setServerValue
(
String
value
)
{
try
{
String
serverValue
=
this
.
propertyFormat
.
unformat
(
value
);
boolean
ok
=
isOk
(
serverValue
);
if
(
ok
)
{
if
(
isCommandBox
)
{
ok
=
AtomicCommandBoxAccessorProxy
.
getInstance
(
serverId
).
setFloat32Value
(
containerId
,
id
,
new
Float
(
serverValue
).
floatValue
());
}
else
{
ok
=
DataAccessor
.
getInstance
(
serverId
).
setFloat32Value
(
containerId
,
id
,
new
Float
(
serverValue
).
floatValue
());
if
(!
ok
)
{
sendPropertyChangedEvent
();
}
}
showSettingPropertyMessage
(
value
);
}
return
ok
;
}
catch
(
NumberFormatException
nfe
)
{
System
.
err
.
println
(
"Number format exception while setting property "
+
getName
()
+
" to "
+
value
);
ConfigManager
.
CONFIGURATION_ERROR
=
true
;
return
false
;
}
}
public
String
getType
()
{
return
"float32"
;
}
}
\ No newline at end of file
src/main/java/fr/ill/ics/core/property/Float64ArrayProperty.java
View file @
633691b0
...
...
@@ -33,7 +33,7 @@ public class Float64ArrayProperty extends FloatArrayProperty {
public
Array
getServerArray
()
{
if
(
isCommandBox
)
{
//int databaseId =
Atomic
CommandBoxAccessor
Proxy
.getInstance(serverId).getDatabaseID(containerId);
//int databaseId = CommandBoxAccessor.getInstance(serverId).getDatabaseID(containerId);
float64Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getFloat64Array
(
getDatabaseID
(),
id
));
}
else
{
float64Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getFloat64Array
(
containerId
,
id
));
...
...
@@ -49,7 +49,7 @@ public class Float64ArrayProperty extends FloatArrayProperty {
public
void
setServerArray
(
Array
array
)
{
if
(
isCommandBox
)
{
//int databaseId =
Atomic
CommandBoxAccessor
Proxy
.getInstance(serverId).getDatabaseID(containerId);
//int databaseId = CommandBoxAccessor.getInstance(serverId).getDatabaseID(containerId);
DataAccessor
.
getInstance
(
serverId
).
setFloat64Array
(
getDatabaseID
(),
id
,
float64Array
.
getArray
());
}
else
{
DataAccessor
.
getInstance
(
serverId
).
setFloat64Array
(
containerId
,
id
,
float64Array
.
getArray
());
...
...
src/main/java/fr/ill/ics/core/property/Float64Property.java
View file @
633691b0
...
...
@@ -18,7 +18,7 @@
package
fr.ill.ics.core.property
;
import
fr.ill.ics.nscclient.command.
Atomic
CommandBoxAccessor
Proxy
;
import
fr.ill.ics.nscclient.command.CommandBoxAccessor
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
import
fr.ill.ics.util.ConfigManager
;
...
...
@@ -31,7 +31,7 @@ public class Float64Property extends FloatProperty {
public
String
getServerValue
()
{
try
{
if
(
isCommandBox
)
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Double
(
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
getFloat64Value
(
containerId
,
id
)).
toString
());
return
this
.
propertyFormat
.
formatForDisplay
(
new
Double
(
CommandBoxAccessor
.
getInstance
(
serverId
).
getFloat64Value
(
containerId
,
id
)).
toString
());
}
else
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Double
(
DataAccessor
.
getInstance
(
serverId
).
getFloat64Value
(
containerId
,
id
)).
toString
());
}
...
...
@@ -48,7 +48,7 @@ public class Float64Property extends FloatProperty {
boolean
ok
=
isOk
(
serverValue
);
if
(
ok
)
{
if
(
isCommandBox
)
{
ok
=
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
setFloat64Value
(
containerId
,
id
,
new
Double
(
serverValue
).
doubleValue
());
ok
=
CommandBoxAccessor
.
getInstance
(
serverId
).
setFloat64Value
(
containerId
,
id
,
new
Double
(
serverValue
).
doubleValue
());
}
else
{
ok
=
DataAccessor
.
getInstance
(
serverId
).
setFloat64Value
(
containerId
,
id
,
new
Double
(
serverValue
).
doubleValue
());
if
(!
ok
)
{
...
...
src/main/java/fr/ill/ics/core/property/Int32ArrayProperty.java
View file @
633691b0
...
...
@@ -33,7 +33,7 @@ public class Int32ArrayProperty extends IntegerArrayProperty {
public
Array
getServerArray
()
{
if
(
isCommandBox
)
{
//int databaseId =
Atomic
CommandBoxAccessor
Proxy
.getInstance(serverId).getDatabaseID(containerId);
//int databaseId = CommandBoxAccessor.getInstance(serverId).getDatabaseID(containerId);
int32Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getInt32Array
(
getDatabaseID
(),
id
));
}
else
{
int32Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getInt32Array
(
containerId
,
id
));
...
...
@@ -50,7 +50,7 @@ public class Int32ArrayProperty extends IntegerArrayProperty {
public
void
setServerArray
(
Array
array
)
{
if
(
isCommandBox
)
{
//int databaseId =
Atomic
CommandBoxAccessor
Proxy
.getInstance(serverId).getDatabaseID(containerId);
//int databaseId = CommandBoxAccessor.getInstance(serverId).getDatabaseID(containerId);
DataAccessor
.
getInstance
(
serverId
).
setInt32Array
(
getDatabaseID
(),
id
,
int32Array
.
getArray
());
}
else
{
DataAccessor
.
getInstance
(
serverId
).
setInt32Array
(
containerId
,
id
,
int32Array
.
getArray
());
...
...
src/main/java/fr/ill/ics/core/property/Int32Property.java
View file @
633691b0
...
...
@@ -18,7 +18,7 @@
package
fr.ill.ics.core.property
;
import
fr.ill.ics.nscclient.command.
Atomic
CommandBoxAccessor
Proxy
;
import
fr.ill.ics.nscclient.command.CommandBoxAccessor
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
import
fr.ill.ics.util.ConfigManager
;
...
...
@@ -30,7 +30,7 @@ public class Int32Property extends IntegerProperty {
public
String
getServerValue
()
{
if
(
isCommandBox
)
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Integer
(
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
getInt32Value
(
containerId
,
id
)).
toString
());
return
this
.
propertyFormat
.
formatForDisplay
(
new
Integer
(
CommandBoxAccessor
.
getInstance
(
serverId
).
getInt32Value
(
containerId
,
id
)).
toString
());
}
else
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Integer
(
DataAccessor
.
getInstance
(
serverId
).
getInt32Value
(
containerId
,
id
)).
toString
());
}
...
...
@@ -43,7 +43,7 @@ public class Int32Property extends IntegerProperty {
boolean
ok
=
isOk
(
serverValue
);
if
(
ok
)
{
if
(
isCommandBox
)
{
ok
=
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
setInt32Value
(
containerId
,
id
,
new
Integer
(
serverValue
).
intValue
());
ok
=
CommandBoxAccessor
.
getInstance
(
serverId
).
setInt32Value
(
containerId
,
id
,
new
Integer
(
serverValue
).
intValue
());
}
else
{
ok
=
DataAccessor
.
getInstance
(
serverId
).
setInt32Value
(
containerId
,
id
,
new
Integer
(
serverValue
).
intValue
());
if
(!
ok
)
{
...
...
src/main/java/fr/ill/ics/core/property/Int64ArrayProperty.java
deleted
100644 → 0
View file @
8344c033
/*
* Nomad Instrument Control Software
*
* Copyright 2011 Institut Laue-Langevin
*
* Licensed under the EUPL, Version 1.1 only (the "License");
* You may not use this work except in compliance with the Licence.
* You may obtain a copy of the Licence at:
*
* http://joinup.ec.europa.eu/software/page/eupl
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the Licence is distributed on an "AS IS" basis,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the Licence for the specific language governing permissions and
* limitations under the Licence.
*/
package
fr.ill.ics.core.property
;
import
fr.ill.ics.core.property.array.Array
;
import
fr.ill.ics.core.property.array.Int64Array
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
public
class
Int64ArrayProperty
extends
IntegerArrayProperty
{
Int64Array
int64Array
=
new
Int64Array
();
public
Int64ArrayProperty
(
int
containerId
,
int
id
,
boolean
isCommandBox
)
{
super
(
containerId
,
id
,
isCommandBox
);
getServerArray
();
// must be left here
}
public
Array
getServerArray
()
{
if
(
isCommandBox
)
{
//int databaseId = AtomicCommandBoxAccessorProxy.getInstance(serverId).getDatabaseID(containerId);
int64Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getInt64Array
(
getDatabaseID
(),
id
));
}
else
{
int64Array
.
setArray
(
DataAccessor
.
getInstance
(
serverId
).
getInt64Array
(
containerId
,
id
));
}
arraySize
=
int64Array
.
getSize
();
return
int64Array
;
}
public
Array
getCurrentArray
()
{
return
int64Array
;
}
public
void
setServerArray
(
Array
array
)
{
if
(
isCommandBox
)
{
//int databaseId = AtomicCommandBoxAccessorProxy.getInstance(serverId).getDatabaseID(containerId);
DataAccessor
.
getInstance
(
serverId
).
setInt64Array
(
getDatabaseID
(),
id
,
int64Array
.
getArray
());
}
else
{
DataAccessor
.
getInstance
(
serverId
).
setInt64Array
(
containerId
,
id
,
int64Array
.
getArray
());
}
}
public
float
getMinValue
()
{
return
int64Array
.
getMinValue
();
}
public
float
getMaxValue
()
{
return
int64Array
.
getMaxValue
();
}
public
String
getType
()
{
return
"int64array"
;
}
}
\ No newline at end of file
src/main/java/fr/ill/ics/core/property/Int64Property.java
deleted
100644 → 0
View file @
8344c033
/*
* Nomad Instrument Control Software
*
* Copyright 2011 Institut Laue-Langevin
*
* Licensed under the EUPL, Version 1.1 only (the "License");
* You may not use this work except in compliance with the Licence.
* You may obtain a copy of the Licence at:
*
* http://joinup.ec.europa.eu/software/page/eupl
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the Licence is distributed on an "AS IS" basis,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the Licence for the specific language governing permissions and
* limitations under the Licence.
*/
package
fr.ill.ics.core.property
;
import
fr.ill.ics.nscclient.command.AtomicCommandBoxAccessorProxy
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
import
fr.ill.ics.util.ConfigManager
;
public
class
Int64Property
extends
IntegerProperty
{
public
Int64Property
(
int
containerId
,
int
id
,
boolean
isCommandBox
)
{
super
(
containerId
,
id
,
isCommandBox
);
}
public
String
getServerValue
()
{
if
(
isCommandBox
)
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Long
(
AtomicCommandBoxAccessorProxy
.
getInstance
(
serverId
).
getInt64Value
(
containerId
,
id
)).
toString
());
}
else
{
return
this
.
propertyFormat
.
formatForDisplay
(
new
Long
(
DataAccessor
.
getInstance
(
serverId
).
getInt64Value
(
containerId
,
id
)).
toString
());
}
}
public
boolean
setServerValue
(
String
value
)
{
try
{
String
serverValue
=
this
.
propertyFormat
.
unformat
(
value
);
boolean
ok
=
isOk
(
serverValue
);
if
(
ok
)
{
if
(
isCommandBox
)
{
ok
=
AtomicCommandBoxAccessorProxy
.
getInstance
(
serverId
).
setInt64Value
(
containerId
,
id
,
new
Long
(
serverValue
).
intValue
());
}
else
{
ok
=
DataAccessor
.
getInstance
(
serverId
).
setInt64Value
(
containerId
,
id
,
new
Long
(
serverValue
).
intValue
());
if
(!
ok
)
{
sendPropertyChangedEvent
();
}
}
showSettingPropertyMessage
(
value
);
}
return
ok
;
}
catch
(
NumberFormatException
nfe
)
{
System
.
err
.
println
(
"Number format exception while setting property "
+
getName
()
+
" to "
+
value
);
ConfigManager
.
CONFIGURATION_ERROR
=
true
;
return
false
;
}
}
public
String
getType
()
{
return
"int64"
;
}
}
\ No newline at end of file
src/main/java/fr/ill/ics/core/property/PropertyFactory.java
View file @
633691b0
...
...
@@ -81,12 +81,6 @@ public class PropertyFactory {
if
(
type
.
equals
(
"int32"
)
||
type
.
equals
(
"long"
))
{
property
=
new
Int32Property
(
containerId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"int64"
))
{
property
=
new
Int64Property
(
containerId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float32"
))
{
property
=
new
Float32Property
(
containerId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float64"
)
||
type
.
equals
(
"double"
))
{
property
=
new
Float64Property
(
containerId
,
id
,
isCommandBox
);
...
...
@@ -99,12 +93,6 @@ public class PropertyFactory {
}
else
if
(
type
.
equals
(
"int32array"
)
||
type
.
equals
(
"longarray"
))
{
property
=
new
Int32ArrayProperty
(
containerId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"int64array"
))
{
property
=
new
Int64ArrayProperty
(
containerId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float32array"
))
{
property
=
new
Float32ArrayProperty
(
containerId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float64array"
)
||
type
.
equals
(
"doublearray"
))
{
property
=
new
Float64ArrayProperty
(
containerId
,
id
,
isCommandBox
);
...
...
@@ -332,10 +320,6 @@ public class PropertyFactory {
if
(
type
.
equals
(
"int32"
)
||
type
.
equals
(
"long"
))
{
clone
=
new
Int32Property
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"int64"
))
{
clone
=
new
Int64Property
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float32"
))
{
clone
=
new
Float32Property
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float64"
)
||
type
.
equals
(
"double"
))
{
clone
=
new
Float64Property
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"boolean"
)
||
type
.
equals
(
"Boolean"
))
{
...
...
@@ -344,10 +328,6 @@ public class PropertyFactory {
clone
=
new
StringProperty
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"int32array"
)
||
type
.
equals
(
"longarray"
))
{
clone
=
new
Int32ArrayProperty
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"int64array"
))
{
clone
=
new
Int64ArrayProperty
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float32array"
))
{
clone
=
new
Float32ArrayProperty
(
databaseId
,
id
,
isCommandBox
);
}
else
if
(
type
.
equals
(
"float64array"
)
||
type
.
equals
(
"doublearray"
))
{
clone
=
new
Float64ArrayProperty
(
databaseId
,
id
,
isCommandBox
);
}
else
{
...
...
src/main/java/fr/ill/ics/core/property/StringProperty.java
View file @
633691b0
...
...
@@ -18,7 +18,7 @@
package
fr.ill.ics.core.property
;
import
fr.ill.ics.nscclient.command.
Atomic
CommandBoxAccessor
Proxy
;
import
fr.ill.ics.nscclient.command.CommandBoxAccessor
;
import
fr.ill.ics.nscclient.dataprovider.DataAccessor
;
public
class
StringProperty
extends
Property
{
...
...
@@ -29,7 +29,7 @@ public class StringProperty extends Property {
public
String
getServerValue
()
{
if
(
isCommandBox
)
{
return
this
.
propertyFormat
.
formatForDisplay
(
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
getStringValue
(
containerId
,
id
));
return
this
.
propertyFormat
.
formatForDisplay
(
CommandBoxAccessor
.
getInstance
(
serverId
).
getStringValue
(
containerId
,
id
));
}
else
{
return
this
.
propertyFormat
.
formatForDisplay
(
DataAccessor
.
getInstance
(
serverId
).
getStringValue
(
containerId
,
id
));
}
...
...
@@ -41,7 +41,7 @@ public class StringProperty extends Property {
if
(
ok
)
{
// try {
if
(
isCommandBox
)
{
ok
=
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
setStringValue
(
containerId
,
id
,
serverValue
);
ok
=
CommandBoxAccessor
.
getInstance
(
serverId
).
setStringValue
(
containerId
,
id
,
serverValue
);
}
else
{
ok
=
DataAccessor
.
getInstance
(
serverId
).
setStringValue
(
containerId
,
id
,
serverValue
);
if
(!
ok
)
{
...
...
src/main/java/fr/ill/ics/nscclient/command/AtomicCommandBoxAccessorProxy.java
deleted
100644 → 0
View file @
8344c033
This diff is collapsed.
Click to expand it.
src/main/java/fr/ill/ics/nscclient/command/CommandBoxAccessor.java
View file @
633691b0
This diff is collapsed.
Click to expand it.
src/main/java/fr/ill/ics/nscclient/command/ServerAtomicCommandBox.java
View file @
633691b0
...
...
@@ -27,19 +27,19 @@ public class ServerAtomicCommandBox extends ServerCommandBox {
}
public
int
getCommandID
()
{
return
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
getCommandID
(
commandBoxId
);
return
CommandBoxAccessor
.
getInstance
(
serverId
).
getCommandID
(
commandBoxId
);
}
public
boolean
isSettings
()
{
return
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
isSettings
(
commandBoxId
);
return
CommandBoxAccessor
.
getInstance
(
serverId
).
isSettings
(
commandBoxId
);
}
public
void
setSettingsFileName
(
String
filename
)
{
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
setSettingsFileName
(
commandBoxId
,
filename
);
CommandBoxAccessor
.
getInstance
(
serverId
).
setSettingsFileName
(
commandBoxId
,
filename
);
}
public
String
getSettingsFileName
()
{
return
Atomic
CommandBoxAccessor
Proxy
.
getInstance
(
serverId
).
getSettingsFileName
(
commandBoxId
);
return
CommandBoxAccessor
.
getInstance
(
serverId
).
getSettingsFileName
(
commandBoxId
);
}
public
int
getNumberOfCommandBoxes
()
{
...
...
src/main/java/fr/ill/ics/nscclient/sessionmanagement/ServerSessionManager.java
View file @
633691b0
...
...
@@ -25,7 +25,7 @@ import java.util.Map;
import
fr.ill.ics.bridge.ControllerManager
;
import
fr.ill.ics.bridge.DriverManager
;
import
fr.ill.ics.bridge.ResourceManager
;
import
fr.ill.ics.nscclient.command.
Atomic
CommandBoxAccessor
Proxy
;
import
fr.ill.ics.nscclient.command.CommandBoxAccessor
;
import
fr.ill.ics.nscclient.command.CommandBoxAccessor
;
import
fr.ill.ics.nscclient.command.CommandZoneAccessorProxy
;
import
fr.ill.ics.nscclient.command.ControlCommandBoxAccessorProxy
;
...
...
@@ -75,7 +75,6 @@ public class ServerSessionManager {
CommandZoneAccessorProxy
.
getInstance
(
serverId
).
init
();
CommandBoxAccessor
.
getInstance
(
serverId
).
init
();
AtomicCommandBoxAccessorProxy
.
getInstance
(
serverId
).
init
();
ScanCommandBoxAccessorProxy
.
getInstance
(
serverId
).
init
();
ForLoopCommandBoxAccessorProxy
.
getInstance
(
serverId
).
init
();
GenericCommandBoxAccessorProxy
.
getInstance
(
serverId
).
init
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment