Ensure not to emit the resource ready signal during the callback
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / internal / controls / control / control-debug.h
1 #ifndef DALI_TOOLKIT_INTERNAL_CONTROL_DEBUG_H
2 #define DALI_TOOLKIT_INTERNAL_CONTROL_DEBUG_H
3 /*
4  * Copyright (c) 2018 Samsung Electronics Co., Ltd.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  */
18
19 #if defined(DEBUG_ENABLED)
20
21 #include <dali/public-api/object/handle.h>
22 #include <dali-toolkit/public-api/controls/control-impl.h>
23 #include <iostream>
24 #include <string>
25
26 namespace Dali
27 {
28 namespace Toolkit
29 {
30 namespace Internal
31 {
32
33 /**
34  * Convert properties of handle into JSON output, separated into 'normal' and 'child' properties.
35  * @param[in] ouputStream the output stream to write to
36  * @param[in] handle The handle of the object from which to retrieve properties
37  * @return The output stream
38  */
39 std::ostream& DumpProperties( std::ostream& outputStream, Handle handle );
40
41 /**
42  * Dumps control internals, visuals and properties to a string in JSON format
43  */
44 std::string DumpControl( const Internal::Control& control );
45
46 /**
47  * Dumps actor internals and properties to a string in JSON format
48  */
49 std::string DumpActor( Actor actor );
50
51 /**
52  * Dumps actor hierarchy from a given root, but expands Control output to encompass Control internals.
53  * Formats the output in JSON.
54  * @param[in] ouputStream the output stream to write to
55  * @param[in] root The root actor
56  */
57 void DumpControlHierarchy( std::ostream& outputStream, Actor rootActor );
58
59 } // namespace Internal
60
61 } // namespace Toolkit
62
63 } // namespace Dali
64
65 #endif
66
67 #endif //DALI_TOOLKIT_INTERNAL_CONTROL_DEBUG_H