FETPAPI 0.3.0.0
This project provides C++ classes which facilitate the developement of ETP1.2 clients and servers.
Loading...
Searching...
No Matches
DataspaceOSDUHandlers.h
1/*-----------------------------------------------------------------------
2Licensed to the Apache Software Foundation (ASF) under one
3or more contributor license agreements. See the NOTICE file
4distributed with this work for additional information
5regarding copyright ownership. The ASF licenses this file
6to you under the Apache License, Version 2.0 (the
7"License"; you may not use this file except in compliance
8with the License. You may obtain a copy of the License at
9
10 http://www.apache.org/licenses/LICENSE-2.0
11
12Unless required by applicable law or agreed to in writing,
13software distributed under the License is distributed on an
14"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15KIND, either express or implied. See the License for the
16specific language governing permissions and limitations
17under the License.
18-----------------------------------------------------------------------*/
19#pragma once
20
21#include "ProtocolHandlers.h"
22
23namespace ETP_NS
24{
25 class FETPAPI_DLL_IMPORT_OR_EXPORT DataspaceOSDUHandlers : public ProtocolHandlers
26 {
27 public:
29 virtual ~DataspaceOSDUHandlers() = default;
30
31 void decodeMessageBody(const Energistics::Etp::v12::Datatypes::MessageHeader & mh, avro::DecoderPtr d);
32
33 virtual void on_GetDataspaceInfo(const Energistics::Etp::v12::Protocol::DataspaceOSDU::GetDataspaceInfo& msg, int64_t correlationId);
34 virtual void on_GetDataspaceInfoResponse(const Energistics::Etp::v12::Protocol::DataspaceOSDU::GetDataspaceInfoResponse& msg, int64_t correlationId);
35 virtual void on_CopyDataspacesContent(const Energistics::Etp::v12::Protocol::DataspaceOSDU::CopyDataspacesContent& msg, int64_t correlationId);
36 virtual void on_CopyDataspacesContentResponse(const Energistics::Etp::v12::Protocol::DataspaceOSDU::CopyDataspacesContentResponse & msg, int64_t correlationId);
37 virtual void on_LockDataspaces(const Energistics::Etp::v12::Protocol::DataspaceOSDU::LockDataspaces& msg, int64_t correlationId);
38 virtual void on_LockDataspacesResponse(const Energistics::Etp::v12::Protocol::DataspaceOSDU::LockDataspacesResponse& msg, int64_t correlationId);
39 virtual void on_CopyToDataspace(const Energistics::Etp::v12::Protocol::DataspaceOSDU::CopyToDataspace& msg, int64_t correlationId);
40 virtual void on_CopyToDataspaceResponse(const Energistics::Etp::v12::Protocol::DataspaceOSDU::CopyToDataspaceResponse & msg, int64_t correlationId);
41
42 std::vector<Energistics::Etp::v12::Datatypes::Object::Dataspace> getDataspaces() const {
43 return dataspaces;
44 }
45 void clearDataspaces() { dataspaces.clear(); }
46
47 std::vector<std::string> getSuccessKeys() const {
48 return successKeys;
49 }
50 void clearSuccessKeys() { successKeys.clear(); }
51
52 private:
53 std::vector<Energistics::Etp::v12::Datatypes::Object::Dataspace> dataspaces;
54 std::vector<std::string> successKeys;
55 };
56}
Definition AbstractSession.h:51
Definition DataspaceOSDUHandlers.h:26
Definition ProtocolHandlers.h:43