Entity entity = entityContainer.getEntity(); LOGGER.finest("Processing entity: " + entity.toString());
/** * Updates the timestamp on the supplied entity. A new entity container may be created if the * existing one is read-only. * * @param entityContainer * The container holding the entity to be modified. * @return A container holding an updated entity. */ public EntityContainer updateTimestamp(EntityContainer entityContainer) { EntityContainer resultContainer; resultContainer = entityContainer.getWriteableInstance(); resultContainer.getEntity().setTimestampContainer(timestamp); return resultContainer; } }
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { // Ask the entity container to invoke the appropriate processing method // for the entity type. entityContainer.process(this); }
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { // Ask the entity container to invoke the appropriate processing method // for the entity type. entityContainer.process(this); }
@Override public final void process(EntityContainer entityContainer) { Entity entity = entityContainer.getEntity();
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { Entity entity; initialize(); entity = entityContainer.getEntity(); userManager.addOrUpdateUser(entityContainer.getEntity().getUser()); changesetManager.addChangesetIfRequired(entity.getChangesetId(), entity.getUser()); entityContainer.process(this); }
/** * Updates the timestamp on the supplied entity. A new entity container may be created if the * existing one is read-only. * * @param entityContainer * The container holding the entity to be modified. * @return A container holding an updated entity. */ public EntityContainer updateTimestamp(EntityContainer entityContainer) { EntityContainer resultContainer; resultContainer = entityContainer.getWriteableInstance(); resultContainer.getEntity().setTimestampContainer(timestamp); return resultContainer; } }
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { entityContainer.process(processor); }
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { Entity entity; initialize(); entity = entityContainer.getEntity(); userManager.addOrUpdateUser(entityContainer.getEntity().getUser()); changesetManager.addChangesetIfRequired(entity.getChangesetId(), entity.getUser()); entityContainer.process(this); }
/** * {@inheritDoc} */ @Override public void process(ChangeContainer change) { // Deleted entities are not visible, all others are. boolean visible = (ChangeAction.Delete != change.getAction()); // Set a visible meta-tag on the entity because the Osmosis data model // doesn't natively support visible. EntityContainer entityContainer = change.getEntityContainer().getWriteableInstance(); entityContainer.getEntity().getMetaTags().put("visible", visible); sink.process(entityContainer); }
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { // Ask the entity container to invoke the appropriate processing method // for the entity type. entityContainer.process(this); }
/** * {@inheritDoc} */ @Override public void process(ChangeContainer change) { // Deleted entities are not visible, all others are. boolean visible = (ChangeAction.Delete != change.getAction()); // Set a visible meta-tag on the entity because the Osmosis data model // doesn't natively support visible. EntityContainer entityContainer = change.getEntityContainer().getWriteableInstance(); entityContainer.getEntity().getMetaTags().put("visible", visible); sink.process(entityContainer); }
/** * {@inheritDoc} */ public void process(EntityContainer entityContainer) { // Ask the entity container to invoke the appropriate processing method // for the entity type. entityContainer.process(this); }
@Override public void process(EntityContainer entityContainer) { try { if (this.entityType == entityContainer.getEntity().getType()) { final T entity = (T) entityContainer.getEntity(); if (filters.stream().noneMatch(filter -> filter.test(entity))) { writer.write(entity); } } } catch (IOException e) { throw new RuntimeException("Unable to write entity", e); } }
/** * {@inheritDoc} */ @Override public void process(EntityContainer entityContainer) { EntityContainer writeableContainer; Entity entity; writeableContainer = entityContainer.getWriteableInstance(); entity = writeableContainer.getEntity(); for (Iterator<Tag> i = entity.getTags().iterator(); i.hasNext();) { Tag tag; tag = i.next(); if (keysToDrop.contains(tag.getKey())) { i.remove(); } else { for (String prefix : keyPrefixesToDrop) { if (tag.getKey().startsWith(prefix)) { i.remove(); break; } } } } sink.process(writeableContainer); }