X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.db.services%2Fsrc%2Forg%2Fsimantics%2Fdb%2Fservices%2Fadaption%2Freflection%2FRelatedResources2.java;fp=bundles%2Forg.simantics.db.services%2Fsrc%2Forg%2Fsimantics%2Fdb%2Fservices%2Fadaption%2Freflection%2FRelatedResources2.java;h=7752727bf80836a5e86b732225b47da229cf2894;hp=f0a32b6b99eed7fac779ad8c87494acc6f325c95;hb=0ae2b770234dfc3cbb18bd38f324125cf0faca07;hpb=24e2b34260f219f0d1644ca7a138894980e25b14 diff --git a/bundles/org.simantics.db.services/src/org/simantics/db/services/adaption/reflection/RelatedResources2.java b/bundles/org.simantics.db.services/src/org/simantics/db/services/adaption/reflection/RelatedResources2.java index f0a32b6b9..7752727bf 100644 --- a/bundles/org.simantics.db.services/src/org/simantics/db/services/adaption/reflection/RelatedResources2.java +++ b/bundles/org.simantics.db.services/src/org/simantics/db/services/adaption/reflection/RelatedResources2.java @@ -1,38 +1,38 @@ -/******************************************************************************* - * Copyright (c) 2007, 2010 Association for Decentralized Information Management - * in Industry THTH ry. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * VTT Technical Research Centre of Finland - initial API and implementation - *******************************************************************************/ -package org.simantics.db.services.adaption.reflection; - -import java.util.Collection; - -import org.simantics.db.Resource; -import org.simantics.db.ReadGraph; -import org.simantics.db.exception.DatabaseException; - -public class RelatedResources2 implements IDynamicAdapter2 { - - Resource relation; - - public RelatedResources2(Resource relation) { - this.relation = relation; - } - - @Override - public Class getType() { - return Collection.class; - } - - @Override - public Collection adapt(ReadGraph g, Resource r) throws DatabaseException { - return g.getObjects(r, relation); - } - -} +/******************************************************************************* + * Copyright (c) 2007, 2010 Association for Decentralized Information Management + * in Industry THTH ry. + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * VTT Technical Research Centre of Finland - initial API and implementation + *******************************************************************************/ +package org.simantics.db.services.adaption.reflection; + +import java.util.Collection; + +import org.simantics.db.Resource; +import org.simantics.db.ReadGraph; +import org.simantics.db.exception.DatabaseException; + +public class RelatedResources2 implements IDynamicAdapter2 { + + Resource relation; + + public RelatedResources2(Resource relation) { + this.relation = relation; + } + + @Override + public Class getType() { + return Collection.class; + } + + @Override + public Collection adapt(ReadGraph g, Resource r) throws DatabaseException { + return g.getObjects(r, relation); + } + +}