src/main/java/me/neznamy/tab/platforms/bukkit/nms/datawatcher/DataWatcher.java
public Object toNMS() throws Exception {
		NMSStorage nms = NMSStorage.getInstance();
		Object nmsWatcher = nms.newDataWatcher.newInstance(new Object[] {null});
		for (DataWatcherItem item : dataValues.values()) {
			if (ProtocolVersion.SERVER_VERSION.getMinorVersion() >= 9) {
				nms.DataWatcher_REGISTER.invoke(nmsWatcher, nms.newDataWatcherObject.newInstance(item.type.position, item.type.classType), item.value);
			} else {
				nms.DataWatcher_REGISTER.invoke(nmsWatcher, item.type.position, item.value);
			}
		}
		return nmsWatcher;
	}
/**
	 * Converts the class into an instance of NMS.DataWatcher
	 * @return an instance of NMS.DataWatcher with same data
	 * @throws Exception - if something fails
	 */
Converts the class into an instance of NMS.DataWatcher
@return an instance of NMS.DataWatcher with same data
@throws Exception - if something fails
Converts the class into an instance of NMS . DataWatcher @return an instance of NMS . DataWatcher with same data @throws Exception - if something fails
public Object toNMS() throws Exception {
		NMSStorage nms = NMSStorage.getInstance();
		Object nmsWatcher = nms.newDataWatcher.newInstance(new Object[] {null});
		for (DataWatcherItem item : dataValues.values()) {
			if (ProtocolVersion.SERVER_VERSION.getMinorVersion() >= 9) {
				nms.DataWatcher_REGISTER.invoke(nmsWatcher, nms.newDataWatcherObject.newInstance(item.type.position, item.type.classType), item.value);
			} else {
				nms.DataWatcher_REGISTER.invoke(nmsWatcher, item.type.position, item.value);
			}
		}
		return nmsWatcher;
	}
public Object toNMS ( ) throws Exception { NMSStorage nms = NMSStorage . getInstance ( ) ; Object nmsWatcher = nms . newDataWatcher . newInstance ( new Object [ ] { null } ) ; for ( DataWatcherItem item : dataValues . values ( ) ) { if ( ProtocolVersion . SERVER_VERSION . getMinorVersion ( ) >= 9 ) { nms . DataWatcher_REGISTER . invoke ( nmsWatcher , nms . newDataWatcherObject . newInstance ( item . type . position , item . type . classType ) , item . value ) ; } else { nms . DataWatcher_REGISTER . invoke ( nmsWatcher , item . type . position , item . value ) ; } } return nmsWatcher ; }
Converts the class into an instance of NMS.DataWatcher
 @return an instance of NMS.DataWatcher with same data
 @throws Exception - if something fails
Converts the class into an instance of NMS . DataWatcher @return an instance of NMS . DataWatcher with same data @throws Exception - if something fails