1/*
2 * Copyright (c) 2022 Huawei Device Co., Ltd.
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 *     http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15
16#ifndef OHOS_HDI_SEQUENCE_DATA_H
17#define OHOS_HDI_SEQUENCE_DATA_H
18
19#include <parcel.h>
20#include <string>
21#include <vector>
22#include "surface.h"
23
24namespace OHOS {
25namespace HDI {
26namespace Camera {
27namespace V1_0 {
28using OHOS::Parcelable;
29using OHOS::Parcel;
30using OHOS::sptr;
31using OHOS::IBufferProducer;
32
33class BufferProducerSequenceable : public Parcelable {
34public:
35    BufferProducerSequenceable() = default;
36    virtual ~BufferProducerSequenceable() = default;
37
38    explicit BufferProducerSequenceable(const sptr<IBufferProducer> &producer):producer_(producer) {}
39    BufferProducerSequenceable &operator=(const BufferProducerSequenceable &other);
40
41    BufferProducerSequenceable(const BufferProducerSequenceable &other):producer_(other.producer_) {}
42
43    bool Marshalling(Parcel &parcel) const override;
44
45    static sptr<BufferProducerSequenceable> Unmarshalling(Parcel &parcel);
46
47    sptr<IBufferProducer> producer_;
48};
49} // V1_0
50} // Camera
51} // HDI
52} // OHOS
53#endif // OHOS_HDI_SEQUENCE_DATA_H
54