All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.javanut.pronghorn.util.parse.MapJSONToPipeBuilder Maven / Gradle / Ivy

Go to download

Ring buffer based queuing utility for applications that require high performance and/or a small footprint. Well suited for embedded and stream based processing.

There is a newer version: 1.1.27
Show newest version
package com.javanut.pronghorn.util.parse;

import com.javanut.pronghorn.pipe.FieldReferenceOffsetManager;
import com.javanut.pronghorn.pipe.MessageSchema;
import com.javanut.pronghorn.pipe.token.TypeMask;
import com.javanut.pronghorn.util.TrieKeyable;

public abstract class MapJSONToPipeBuilder, K extends Enum & TrieKeyable> {

	protected final K[] allEnums;
	protected final int msgIdx;
	protected final FieldReferenceOffsetManager from;
	protected final int[] bitFields;
	
	protected MapJSONToPipeBuilder(M schema, Class enums, int msgIdx, int ... bitFields) {
		this.allEnums = enums.getEnumConstants();
		this.msgIdx = msgIdx;
		this.from = MessageSchema.from(schema);
		this.bitFields = bitFields;
	}	
	
	protected long buildUniqueId(K ... path) {
		
		long accum = 0;
		for(int i = 0; i




© 2015 - 2025 Weber Informatics LLC | Privacy Policy