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 <boost/function.hpp>
25 #include <dali/internal/common/owner-pointer.h>
26 #include <dali/internal/common/owner-container.h>
27 #include <dali/public-api/animation/alpha-functions.h>
28 #include <dali/public-api/animation/time-period.h>
29 #include <dali/public-api/common/dali-common.h>
38 class AnimatorConnectorBase;
40 typedef OwnerPointer<AnimatorConnectorBase> AnimatorConnectorPtr;
42 typedef OwnerContainer< AnimatorConnectorBase* > AnimatorConnectorContainer;
44 typedef AnimatorConnectorContainer::Iterator AnimatorConnectorIter;
45 typedef AnimatorConnectorContainer::ConstIterator AnimatorConnectorConstIter;
48 * An abstract base class for animator connectors.
50 class AnimatorConnectorBase
57 AnimatorConnectorBase(AlphaFunction alpha, const TimePeriod& period)
59 mAlphaFunction(alpha),
67 virtual ~AnimatorConnectorBase()
72 * Set the parent of the AnimatorConnector.
73 * @pre The connector does not already have a parent.
74 * @param [in] parent The parent object.
76 virtual void SetParent(Animation& parent) = 0;
79 * Retrieve the parent of the AnimatorConnector.
80 * @return The parent object, or NULL.
82 Animation* GetParent()
89 Animation* mParent; ///< The parent owns the connector.
91 AlphaFunction mAlphaFunction;
92 TimePeriod mTimePeriod;
95 } // namespace Internal
99 #endif // __DALI_INTERNAL_ANIMATOR_CONNECTOR_BASE_H__