Fix for x86_64 build fail
[platform/upstream/connectedhomeip.git] / src / app / MessageDef / ListBuilder.h
1 /**
2  *
3  *    Copyright (c) 2020 Project CHIP Authors
4  *    Copyright (c) 2016-2017 Nest Labs, Inc.
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  *    @file
20  *      This file defines List builder in CHIP interaction model
21  *
22  */
23
24 #pragma once
25
26 #ifndef _CHIP_INTERACTION_MODEL_MESSAGE_DEF_LIST_BUILDER_H
27 #define _CHIP_INTERACTION_MODEL_MESSAGE_DEF_LIST_BUILDER_H
28
29 #include "Builder.h"
30 #include "Parser.h"
31 #include <core/CHIPCore.h>
32 #include <core/CHIPTLV.h>
33 #include <support/CodeUtils.h>
34 #include <support/logging/CHIPLogging.h>
35 #include <util/basic-types.h>
36
37 namespace chip {
38 namespace app {
39 class ListBuilder : public chip::app::Builder
40 {
41 protected:
42     ListBuilder();
43
44 public:
45     /**
46      * Init the TLV array container with an particular context tag.
47      * Required to implement arrays of arrays, and to test ListBuilder.
48      *
49      * @param[in]   apWriter    Pointer to the TLVWriter that is encoding the message.
50      * @param[in]   aContextTagToUse    A contextTag to use.
51      *
52      * @return                  CHIP_ERROR codes returned by chip::TLV objects.
53      */
54
55     CHIP_ERROR Init(chip::TLV::TLVWriter * const apWriter, const uint8_t aContextTagToUse);
56     /**
57      * Init the TLV array container with an anonymous tag.
58      * Required to implement arrays of arrays, and to test ListBuilder.
59      *
60      * @param[in]   apWriter    Pointer to the TLVWriter that is encoding the message.
61      *
62      * @return                  CHIP_ERROR codes returned by chip::TLV objects.
63      */
64     CHIP_ERROR Init(chip::TLV::TLVWriter * const apWriter);
65 };
66
67 }; // namespace app
68 }; // namespace chip
69
70 #endif // _CHIP_INTERACTION_MODEL_MESSAGE_DEF_LIST_BUILDER_H