MCPcopy Index your code
hub / github.com/java-native-access/jna / testWriteUnion

Method testWriteUnion

test/com/sun/jna/UnionTest.java:106–113  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

104 }
105
106 public void testWriteUnion() {
107 SizedUnion u = new SizedUnion();
108 final int VALUE = 0x12345678;
109 u.intField = VALUE;
110 u.setType(int.class);
111 u.write();
112 assertEquals("Wrong value written", VALUE, u.getPointer().getInt(0));
113 }
114
115 public void testReadUnion() {
116 SizedUnion u = new SizedUnion();

Callers

nothing calls this directly

Calls 4

setTypeMethod · 0.80
getPointerMethod · 0.65
writeMethod · 0.45
getIntMethod · 0.45

Tested by

no test coverage detected