2 * ============LICENSE_START====================================================
4 * ===========================================================================
5 * Copyright (c) 2018 AT&T Intellectual Property. All rights reserved.
6 * ===========================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END====================================================
22 package org.onap.aaf.misc.env;
24 import java.util.List;
26 public interface Store {
28 * Returns the Slot assigned to the supplied name.
31 * The name of the Slot to acquire.
33 * The Slot associated with the supplied name.
35 public abstract Slot slot(String name);
38 * Returns the existing Slot associated with the supplied name, or null if it doesn't exist.
41 * The name of the Slot to get.
43 * The Slot assigned to the supplied name, or null if it doesn't exist.
46 public abstract Slot existingSlot(String name);
49 * Returns the names used while creating Slots in a List
53 public abstract List<String> existingSlotNames();
56 * Returns the StaticSlot assigned to the supplied name.
59 * The name of the StaticSlot to acquire.
61 * The StaticSlot associated with the supplied name.
63 public abstract StaticSlot staticSlot(String name);
66 * Returns the names used while creating Static Slots in a List
70 public abstract List<String> existingStaticSlotNames();
73 * Store the supplied value in the StaticSlot of the Organizer's static state.
76 * The StaticSlot used to store the object.
78 * The object to store.
80 public abstract void put(StaticSlot slot, Object value);
83 * Returns an Object from the Organizer's static state, or the Default if null
86 * The StaticSlot to retrieve the data from.
88 * The Object located in the supplied StaticSlot of the Organizer's static state.
90 public abstract<T> T get(StaticSlot slot, T dflt);
93 * Returns an Object from the Organizer's static state
96 * The StaticSlot to retrieve the data from.
98 * The Object located in the supplied StaticSlot of the Organizer's static state.
100 public abstract<T> T get(StaticSlot slot);
103 // * Transfer (targeted) Args to Slots
105 // * Transfer Strings with format "tag=value" into Static Slots
107 // public abstract void transfer(String args[], String ... tagss);