Skip to content

Commit 002e192

Browse files
committed
Remove modifications from master branch
1 parent d7bc56e commit 002e192

File tree

2 files changed

+2
-45
lines changed

2 files changed

+2
-45
lines changed

app/display/runtime/src/main/java/org/csstudio/display/builder/runtime/WidgetRuntime.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -483,3 +483,4 @@ public void stop() {
483483
started = new CountDownLatch(1);
484484
}
485485
}
486+

core/pv-ca/src/main/java/org/phoebus/pv/ca/JCA_PV.java

Lines changed: 1 addition & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,6 @@
1212
import java.util.concurrent.atomic.AtomicReference;
1313
import java.util.logging.Level;
1414

15-
import org.epics.vtype.VBoolean;
16-
import org.epics.vtype.VDouble;
17-
import org.epics.vtype.VEnum;
18-
import org.epics.vtype.VFloat;
19-
import org.epics.vtype.VInt;
20-
import org.epics.vtype.VLong;
21-
import org.epics.vtype.VShort;
22-
import org.epics.vtype.VString;
2315
import org.epics.vtype.VType;
2416
import org.phoebus.pv.PV;
2517

@@ -468,36 +460,8 @@ public CompletableFuture<?> asyncWrite(final Object new_value) throws Exception
468460
return result;
469461
}
470462

471-
private void performWrite(final Object newvalue, final PutListener put_listener) throws Exception
463+
private void performWrite(final Object new_value, final PutListener put_listener) throws Exception
472464
{
473-
//Manage type of PV to convert the value in good format
474-
VType vType = read();
475-
Object new_value = newvalue;
476-
if(vType instanceof VString) {
477-
new_value = newvalue.toString();
478-
}
479-
else if(vType instanceof VDouble) {
480-
new_value = Double.valueOf(new_value.toString());
481-
}
482-
else if(vType instanceof VLong) {
483-
new_value = Double.valueOf(new_value.toString()).longValue();
484-
}
485-
else if(vType instanceof VFloat) {
486-
new_value = Double.valueOf(new_value.toString()).floatValue();
487-
}
488-
else if(vType instanceof VInt) {
489-
new_value = Double.valueOf(new_value.toString()).intValue();
490-
}
491-
else if(vType instanceof VShort) {
492-
new_value = Double.valueOf(new_value.toString()).shortValue();
493-
}
494-
else if(vType instanceof VEnum) {
495-
new_value = Double.valueOf(new_value.toString()).intValue();
496-
}
497-
else if(vType instanceof VBoolean) {
498-
new_value = Boolean.parseBoolean(new_value.toString());
499-
}
500-
501465
if (new_value instanceof String)
502466
{
503467
if (channel.getFieldType().isBYTE() && channel.getElementCount() > 1)
@@ -588,14 +552,6 @@ else if (new_value instanceof Long)
588552
channel.put(val);
589553
}
590554
}
591-
else if (new_value instanceof Boolean)
592-
{
593-
final short val = ((Boolean)new_value) ? (short)1 : (short)0;
594-
if (put_listener != null)
595-
channel.put(val, put_listener);
596-
else
597-
channel.put(val);
598-
}
599555
else if (new_value instanceof Long [])
600556
{ // Channel only supports put(int[]), not long[]
601557
logger.log(Level.WARNING, "Truncating long[] to int[] for PV " + getName());

0 commit comments

Comments
 (0)