@Override public GenericAdapterSetDescription declareModel() { GenericAdapterSetDescription adapterDescription = new GenericAdapterSetDescription(); adapterDescription.setAdapterId(GenericAdapterSetDescription.ID); adapterDescription.setUri(GenericAdapterSetDescription.ID); adapterDescription.setAppId(GenericAdapterSetDescription.ID); return adapterDescription; }
public GenericAdapterSetDescription(GenericAdapterSetDescription other) { super(other); if (other.getFormatDescription() != null) this.formatDescription = new FormatDescription(other.getFormatDescription()); if (other.getProtocolDescription() != null) this.protocolDescription = new ProtocolSetDescription(other.getProtocolDescription()); }
@Override public GenericAdapterSetDescription declareModel() { GenericAdapterSetDescription adapterDescription = new GenericAdapterSetDescription(); adapterDescription.setAdapterId(GenericAdapterSetDescription.ID); adapterDescription.setUri(GenericAdapterSetDescription.ID); return adapterDescription; }
adapterDescription = new GenericAdapterSetDescription((GenericAdapterSetDescription) adapterDescription); } else if (adapterDescription instanceof GenericAdapterStreamDescription) { adapterDescription = new GenericAdapterStreamDescription((GenericAdapterStreamDescription) adapterDescription); String id = ((GenericAdapterSetDescription) adapterDescription).getFormatDescription().getElementId(); id = id + "/" + UUID.randomUUID().toString(); ((GenericAdapterSetDescription) adapterDescription).getFormatDescription().setElementId(id); id = ((GenericAdapterSetDescription) adapterDescription).getProtocolDescription().getElementId(); id = id + "/" + UUID.randomUUID().toString(); ((GenericAdapterSetDescription) adapterDescription).getProtocolDescription().setElementId(id); id = ((GenericAdapterSetDescription) adapterDescription).getDataSet().getElementId(); id = id + "/" + UUID.randomUUID().toString(); ((GenericAdapterSetDescription) adapterDescription).getDataSet().setElementId(id);
public static EventSchema getEventSchema(GenericAdapterDescription adapterDescription) { if(adapterDescription instanceof GenericAdapterStreamDescription) { return ((GenericAdapterStreamDescription) adapterDescription).getDataStream().getEventSchema(); } else if (adapterDescription instanceof GenericAdapterSetDescription) { return ((GenericAdapterSetDescription) adapterDescription).getDataSet().getEventSchema(); } return null; } }
public GenericAdapterSetDescription() { super(ID, "GenericAdapterSetDescription", ""); setAdapterId(ID); }
private static EventGrounding getEventGrounding(AdapterDescription adapterDescription) { EventGrounding eventGrounding = null; if (adapterDescription instanceof SpecificAdapterSetDescription) { eventGrounding = ((SpecificAdapterSetDescription) adapterDescription).getDataSet().getEventGrounding(); } else if (adapterDescription instanceof GenericAdapterSetDescription) { eventGrounding = ((GenericAdapterSetDescription) adapterDescription).getDataSet().getEventGrounding(); } else { eventGrounding = adapterDescription.getEventGrounding(); } return eventGrounding; }