]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.db.layer0/src/org/simantics/db/layer0/util/ResourceCutRepresentation.java
Always write model activation information in activations VG
[simantics/platform.git] / bundles / org.simantics.db.layer0 / src / org / simantics / db / layer0 / util / ResourceCutRepresentation.java
1 package org.simantics.db.layer0.util;
2
3 import java.util.Collection;
4 import java.util.Map;
5
6 import org.simantics.db.RequestProcessor;
7 import org.simantics.db.Resource;
8 import org.simantics.db.layer0.util.SimanticsClipboard.Representation;
9 import org.simantics.utils.datastructures.hints.IHintContext.Key;
10
11 class ResourceCutRepresentation implements Representation {
12
13         private Collection<Resource> resources;
14         
15         public ResourceCutRepresentation(Collection<Resource> resources) {
16                 this.resources = resources;
17         }
18
19         @Override
20         public Key getKey() {
21                 return SimanticsKeys.KEY_CUT_RESOURCES;
22         }
23         
24         @SuppressWarnings("unchecked")
25         @Override
26         public <T> T getValue(RequestProcessor processor, Map<String,Object> hints) {
27                 
28                 return (T)resources;
29                 
30         }
31         
32 }