@Override public void quad(Quad quad) { action.execute(JenaConverter.toQuadruple( quad, checkQuadrupleType, checkQuadrupleMetaInformation)); } };
/** * {@inheritDoc} */ @Override public Iterator<T> iterator() { return this.pool.iterator(); }
/** * Serializes the specified {@code binding} into the given output stream. By * default the output is not compressed. * * @param out * the output stream to write in. * @param binding * the {@link Binding} to serialize. */ public static void serialize(OutputStream out, Binding binding) { serialize(out, binding, false); }
public static List<Quadruple> read(String uri) { return read(uri, true, true); }
/** * Deserializes a {@link Binding} by reading bytes from the specified input * stream. It assumes the output is not compressed. * * @param in * the input stream to read from. * * @return the {@link Binding} read from the input stream. */ public static Binding deserializeBinding(InputStream in) { return deserializeBinding(in, false); }
/** * Deserializes a {@link Model} by reading bytes from the specified input * stream. It assumes the output is not compressed. * * @param in * the input stream to read from. * * @return the {@link Model} read from the input stream. */ public static Model deserializeModel(InputStream in) { return deserializeModel(in, false); }
/** * Parses the string argument as a UniqueId. * * @param uniqueId * a <code>String</code> containing the <code>UniqueId</code> * representation to be parsed. * * @return the <code>UniqueId</code> represented by the argument. */ public static final UniqueId parseUniqueId(String uniqueId) { return new UniqueId(decode(uniqueId)); }
/** * Deserializes a {@link ResultSet} by reading bytes from the specified * input stream. It assumes the output is not compressed. * * @param in * the input stream to read from. * * @return the {@link ResultSet} read from the input stream. */ public static ResultSet deserializeResultSet(InputStream in) { return deserializeResultSet(in, false); }
/** * {@inheritDoc} */ @Override public String toString() { if (this.toString == null) { this.toString = encode(this.value); } return this.toString; }
/** * {@inheritDoc} */ @Override public String toString() { return this.pool.toString(); }
/** * Converts a quadruple from the Jena API to the EventCloud API. * * @param quad * the Jena quadruple to convert. * * @return a quadruple instance from the EventCloud API. */ public static Quadruple toQuadruple(Quad quad) { return toQuadruple(quad, true, true); }
public ComponentPool(Supplier<? extends T> supplier) { this.pool = new Pool<T>(supplier); }
public void allocate(int nb) { this.pool.allocate(nb); }
public void clear() { this.pool.clear(); }
/** * Returns the address declared in the specified * {@link W3CEndpointReference W3C endpoint reference}. * * @param endpointReference * the endpoint reference to analyze. * * @return the address declared in the specified W3C endpoint reference. */ public static String getAddress(W3CEndpointReference endpointReference) { Object address = ReflectionUtils.getFieldValue(endpointReference, "address"); if (address != null) { return (String) ReflectionUtils.getFieldValue(address, "uri"); } return null; }
public SemanticTracker borrow(DeploymentConfiguration deploymentConfiguration, String networkName) { SemanticTracker resource = super.pool.borrow(); SemanticFactory.initGenericSemanticTracker( resource, deploymentConfiguration, networkName); return resource; }
/** * Serializes the specified {@code resultSet} into the given output stream * by using the TSV format. By default the output is not compressed. * * @param out * the output stream to write in. * @param resultSet * the {@link ResultSet} to serialize. */ public static void serialize(OutputStream out, ResultSet resultSet) { serialize(out, resultSet, false); }
public static void read(String uri, Callback<Quadruple> action) { read(uri, action, true, true); }
@Override public void quad(Quad quad) { action.execute(JenaConverter.toQuadruple( quad, checkQuadrupleType, checkQuadrupleMetaInformation)); } };
/** * Serializes the specified {@code model} by using the TURTLE syntax. By * default the output is not compressed. * * @param out * the output stream to write in. * @param model * the {@link Model} to serialize. */ public static void serialize(OutputStream out, Model model) { serialize(out, model, false); }