comparison flys-artifacts/src/main/java/de/intevation/flys/collections/FLYSArtifactCollection.java @ 1822:6ed439ff61bf

Changed theme-mapping mechanism to include further condition (on master-artifacts attributes), added point themes for longitudinal.ws for calculations at locations. flys-artifacts/trunk@3151 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Thu, 03 Nov 2011 10:25:23 +0000
parents 661dfad9910a
children 9562ca537143
comparison
equal deleted inserted replaced
1821:e55f1a851923 1822:6ed439ff61bf
492 return persistent != null ? persistent.getArtifact() : null; 492 return persistent != null ? persistent.getArtifact() : null;
493 } 493 }
494 494
495 495
496 /** 496 /**
497 * Returns the attribute that belongs to an artifact stored in this 497 * Returns the attribute that belongs to an artifact and facet stored in
498 * collection. 498 * this collection.
499 * 499 *
500 * @param uuid The Artifact's uuid. 500 * @param uuid The Artifact's uuid.
501 * @param outname The name of the requested output. 501 * @param outname The name of the requested output.
502 * @param facet The name of the requested facet. 502 * @param facet The name of the requested facet.
503 * @param context The CallContext. 503 * @param context The CallContext.
721 721
722 FLYSContext flysContext = context instanceof FLYSContext 722 FLYSContext flysContext = context instanceof FLYSContext
723 ? (FLYSContext) context 723 ? (FLYSContext) context
724 : (FLYSContext) context.globalContext(); 724 : (FLYSContext) context.globalContext();
725 725
726 // Push artifact in flysContext.
727 ArtifactDatabase db = context.getDatabase();
728 try {
729 FLYSArtifact artifact = (FLYSArtifact) db.getRawArtifact(uuid);
730 log.debug("Got raw artifact");
731 flysContext.put(flysContext.ARTIFACT_KEY, artifact);
732 }
733 catch (Exception e) {
734 log.error("Exception caught when trying to get art.", e);
735 }
736
726 Theme t = ThemeFactory.getTheme(flysContext, facet, pattern); 737 Theme t = ThemeFactory.getTheme(flysContext, facet, pattern);
727 738
728 if (t != null) { 739 if (t != null) {
729 t.setFacet(facet); 740 t.setFacet(facet);
730 t.setIndex(index); 741 t.setIndex(index);

http://dive4elements.wald.intevation.org