@Override public boolean isCoercibleTo(PDataType targetType) { return targetType.equals(this) || PUnsignedSmallint.INSTANCE.isCoercibleTo(targetType) || PTinyint.INSTANCE.isCoercibleTo(targetType); }
@Override public boolean isCoercibleTo(PDataType targetType) { return targetType.equals(this) || PUnsignedSmallint.INSTANCE.isCoercibleTo(targetType) || PTinyint.INSTANCE.isCoercibleTo(targetType); }
@Override public boolean isCoercibleTo(PDataType targetType) { return targetType.equals(this) || PUnsignedSmallint.INSTANCE.isCoercibleTo(targetType) || PTinyint.INSTANCE.isCoercibleTo(targetType); }
assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PDouble.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PFloat.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PInteger.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PInteger.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PInteger.INSTANCE, (short)0)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PLong.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PLong.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PLong.INSTANCE, (short)0)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedLong.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedLong.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedLong.INSTANCE, (short)0)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedInt.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedInt.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedInt.INSTANCE, (short)0)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PSmallint.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PSmallint.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PSmallint.INSTANCE, (short)0)); assertFalse(PUnsignedSmallint.INSTANCE.isCoercibleTo(PTinyint.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PTinyint.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PTinyint.INSTANCE, (short)0)); assertFalse(PUnsignedSmallint.INSTANCE.isCoercibleTo(PTinyint.INSTANCE, (short)1000)); assertFalse(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedTinyint.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedTinyint.INSTANCE, (short)10)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedTinyint.INSTANCE, (short)0)); assertFalse(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedTinyint.INSTANCE, (short)1000)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedDouble.INSTANCE)); assertTrue(PUnsignedSmallint.INSTANCE.isCoercibleTo(PUnsignedFloat.INSTANCE));