Create a new {@link UniversalIdIntQueueMessage}.

@param data
@return
@since 0.6.2.3
188172
public static UniversalIdIntQueueMessage newInstance(Map<String, Object> data) {
        UniversalIdIntQueueMessage msg = newInstance();
        return msg.fromMap(data);
    }
552869
public void newDataReady(DataType data) {
		ArrayList<Runnable> list;
		synchronized (this) {
			if (end) throw new IllegalStateException("method endOfData already called, method newDataReady is not allowed anymore");
			waitingData.addLast(data);
			list = listeners;
			listeners = null;
		}
		if (list != null) {
			for (Runnable listener : list) listener.run();
		}
		// notify after listeners
		synchronized (this) {
			this.notify();
		}
	}
1275060
public static UniversalIdIntQueueMessage newInstance(byte[] content) {
        UniversalIdIntQueueMessage msg = newInstance();
        msg.setContent(content);
        return msg;
    }
65606
public Long createEvent(String taskName, String queueId, String data, String key2) {
		return tedDriverImpl.createEvent(taskName, queueId, data, key2);
	}
308089
public DistributedIdQueue<T>      buildIdQueue()
    {
        return new DistributedIdQueue<T>
        (
            client,
            consumer,
            serializer,
            queuePath,
            factory,
            executor,
            Integer.MAX_VALUE,
            false,
            lockPath,
            maxItems,
            putInBackground,
            finalFlushMs
        );
    }
723009
public Message getOrCreateMessage(TextChannel channel, JsonNode data) {
        long id = Long.parseLong(data.get("id").asText());
        synchronized (messages) {
            return getCachedMessageById(id).orElseGet(() -> new MessageImpl(this, channel, data));
        }
    }
303379
public static Map<String, List<Interaction>> getConnectionListenerData(List<Interaction> data)
   {
      Map<String, List<Interaction>> result = new TreeMap<String, List<Interaction>>();

      for (int i = 0; i < data.size(); i++)
      {
         Interaction interaction = data.get(i);

         List<Interaction> l = result.get(interaction.getConnectionListener());

         if (l == null)
            l = new ArrayList<Interaction>();

         l.add(interaction);

         result.put(interaction.getConnectionListener(), l);
      }

      return result;
   }
414362
public boolean enQueue( int data )
    {
        Entry o = new Entry(data, tail.prev, tail);
        tail.prev.next = o;
        tail.prev = o;
        
        //set the size
        size++;
        
        return true;
    }
951755
@Override
    public AbstractLessLockingUniversalSingleStorageJdbcQueue init() throws Exception {
        super.init();

        if (getMessageFactory() == null) {
            setMessageFactory(UniversalIdIntQueueMessageFactory.INSTANCE);
        }

        SQL_COUNT = MessageFormat.format(SQL_COUNT, getTableName());
        SQL_COUNT_EPHEMERAL = MessageFormat.format(SQL_COUNT_EPHEMERAL, getTableNameEphemeral());

        return this;
    }
339063
@Override
    public UnblockingMessage createUBL() {
        UnblockingMessage msg = new UnblockingMessageImpl(_UBL_HOLDER.mandatoryCodes, _UBL_HOLDER.mandatoryVariableCodes,
                _UBL_HOLDER.optionalCodes, _UBL_HOLDER.mandatoryCodeToIndex, _UBL_HOLDER.mandatoryVariableCodeToIndex,
                _UBL_HOLDER.optionalCodeToIndex);
        return msg;
    }
765090
public TransactionQueueData add(TransactionQueueData data) {
        return new TransactionQueueData
            (null,
             Math.min(mSnapshotStart, data.mSnapshotStart),
             Math.max(mSnapshotEnd, data.mSnapshotEnd),
             mQueueSize + data.mQueueSize,
             mThreadCount + data.mThreadCount,
             mServicingCount + data.mServicingCount,
             Math.max(mPeakQueueSize, data.mPeakQueueSize),
             Math.max(mPeakThreadCount, data.mPeakThreadCount),
             Math.max(mPeakServicingCount, data.mPeakServicingCount),
             mTotalEnqueueAttempts + data.mTotalEnqueueAttempts,
             mTotalEnqueued + data.mTotalEnqueued,
             mTotalServiced + data.mTotalServiced,
             mTotalExpired + data.mTotalExpired,
             mTotalServiceExceptions + data.mTotalServiceExceptions,
             mTotalUncaughtExceptions + data.mTotalUncaughtExceptions,
             mTotalQueueDuration + data.mTotalQueueDuration,
             mTotalServiceDuration + data.mTotalServiceDuration
             );
    }
463518
public void sendMessages(byte[] data)
    {
        try
        {
            out.write(data);
            out.flush();
        }
        catch (final IOException exception)
        {
            Verbose.exception(exception);
        }
    }
878531
public static UnitResponse createSuccess(Object data, String errMsg) {
        return createSuccess(data).setMessage(errMsg);
    }
1212354
private UninitializedMessageException
      newUninitializedMessageException(MessageType message) {
    if (message instanceof AbstractMessageLite) {
      return ((AbstractMessageLite) message).newUninitializedMessageException();
    }
    return new UninitializedMessageException(message);
  }
1273789
public AsyncWork<OutputResultType, OutputErrorType> write(InputType data) throws IOException {
		do {
			SynchronizationPoint<NoException> lk;
			synchronized (waiting) {
				// if cancelled or errored, return immediately
				if (error != null) return new AsyncWork<>(null, error);
				if (cancelled != null) return new AsyncWork<>(null, null, cancelled);
				
				AsyncWork<OutputResultType, OutputErrorType> op;
				// if ready, write immediately
				if (isReady) {
					isReady = false;
					op = lastWrite = executor.execute(data);
					lastWrite.listenInline(new WriteListener(data, op, null));
					return op;
				}
				// not ready
				if (!waiting.isFull()) {
					op = new AsyncWork<>();
					waiting.addLast(new Pair<>(data, op));
					lastWrite = op;
					return op;
				}
				// full
				if (lock != null)
					throw new IOException("Concurrent write");
				lock = new SynchronizationPoint<>();
				lk = lock;
			}
			lk.block(0);
		} while (true);
	}
1315819
@Override
    public boolean requeueSilent(IQueueMessage<ID, DATA> _msg) throws QueueException.QueueIsFull {
        IQueueMessage<ID, DATA> msg = _msg.clone();
        putToQueue(msg);
        if (!isEphemeralDisabled()) {
            ephemeralStorage.remove(msg.getId());
        }
        return true;
    }
1220145
@Override
    public UniversalIdIntQueueMessage fromBytes(byte[] data) {
        try {
            UniversalIdIntQueueMessage other = BaseUniversalQueueMessage.fromBytes(data,
                    UniversalIdIntQueueMessage.class);
            fromMap(other.toMap());
            return this;
        } catch (InstantiationException | IllegalAccessException e) {
            throw new RuntimeException(e);
        }
    }