1 #ifndef __DALI_INTERNAL_ANIMATOR_CONNECTOR_BASE_H__
2 #define __DALI_INTERNAL_ANIMATOR_CONNECTOR_BASE_H__
5 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
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.
22 #include <dali/internal/common/owner-pointer.h>
23 #include <dali/internal/common/owner-container.h>
24 #include <dali/public-api/animation/alpha-functions.h>
25 #include <dali/public-api/animation/time-period.h>
26 #include <dali/public-api/common/dali-common.h>
35 class AnimatorConnectorBase;
37 typedef OwnerPointer<AnimatorConnectorBase> AnimatorConnectorPtr;
39 typedef OwnerContainer< AnimatorConnectorBase* > AnimatorConnectorContainer;
41 typedef AnimatorConnectorContainer::Iterator AnimatorConnectorIter;
42 typedef AnimatorConnectorContainer::ConstIterator AnimatorConnectorConstIter;
45 * An abstract base class for animator connectors.
47 class AnimatorConnectorBase
54 AnimatorConnectorBase(AlphaFunction alpha, const TimePeriod& period)
56 mAlphaFunction(alpha),
64 virtual ~AnimatorConnectorBase()
69 * Set the parent of the AnimatorConnector.
70 * @pre The connector does not already have a parent.
71 * @param [in] parent The parent object.
73 virtual void SetParent(Animation& parent) = 0;
76 * Retrieve the parent of the AnimatorConnector.
77 * @return The parent object, or NULL.
79 Animation* GetParent()
86 Animation* mParent; ///< The parent owns the connector.
88 AlphaFunction mAlphaFunction;
89 TimePeriod mTimePeriod;
92 } // namespace Internal
96 #endif // __DALI_INTERNAL_ANIMATOR_CONNECTOR_BASE_H__