01: /*
02: * Copyright 2006 Pentaho Corporation. All rights reserved.
03: * This software was developed by Pentaho Corporation and is provided under the terms
04: * of the Mozilla Public License, Version 1.1, or any later version. You may not use
05: * this file except in compliance with the license. If you need a copy of the license,
06: * please go to http://www.mozilla.org/MPL/MPL-1.1.txt. The Original Code is the Pentaho
07: * BI Platform. The Initial Developer is Pentaho Corporation.
08: *
09: * Software distributed under the Mozilla Public License is distributed on an "AS IS"
10: * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. Please refer to
11: * the license for the specific language governing your rights and limitations.
12: *
13: * @created Jun 24, 2005
14: * @author Marc Batchelor
15: *
16: */
17:
18: package org.pentaho.core.repository;
19:
20: import java.util.Collection;
21:
22: import org.pentaho.core.session.IPentahoSession;
23: import org.pentaho.core.repository.RepositoryException;
24: import org.pentaho.core.repository.IRuntimeElement;
25: import org.pentaho.util.logging.ILogger;
26:
27: public interface IRuntimeRepository extends ILogger {
28:
29: /**
30: * Loads a runtimeElement by it's ID.
31: *
32: * @param instanceId
33: * The instance ID for the Runtime Element
34: * @param allowableReadAttributeNames
35: * The attribute names that are allowed to be read by this
36: * process
37: * @return The RuntimeElement
38: * @throws RepositoryException
39: */
40: public IRuntimeElement loadElementById(String instanceId,
41: Collection allowableReadAttributeNames)
42: throws RepositoryException;
43:
44: /**
45: * Constructs a new Runtime Element.
46: *
47: * @param parentId
48: * The parent of the Runtime Element
49: * @param parentType
50: * The parent type of the Runtime Element
51: * @param transientOnly
52: * Indicates whether this runtime element will be transient only
53: * (unsaved) or persistent. If true, then this will be in memory
54: * only, and will not be persisted when it goes out of scope.
55: * @return The new Runtime element
56: */
57: public IRuntimeElement newRuntimeElement(String parentId,
58: String parentType, boolean transientOnly);
59:
60: /**
61: * Constructs a new Runtime Element.
62: *
63: * @param parentId
64: * The parent of the Runtime Element
65: * @param parentType
66: * The parent type of the Runtime Element
67: * @param solutionId
68: * The ID of the Solution this Runtime Element is associated with
69: * @param transientOnly
70: * Indicates whether this runtime element will be transient only
71: * (unsaved) or persistent. If true, then this will be in memory
72: * only, and will not be persisted when it goes out of scope.
73: * @return The new Runtime element
74: */
75: public IRuntimeElement newRuntimeElement(String parentId,
76: String parentType, String solutionId, boolean transientOnly);
77:
78: /**
79: * @param sess
80: * The IPentahoSession to set
81: */
82: public void setSession(IPentahoSession sess);
83:
84: public boolean usesHibernate();
85:
86: }
|