Skip to content

Commit

Permalink
[java] fix the SWIG interface for java
Browse files Browse the repository at this point in the history
The commissioner.i file is behind the APIs in include/commissioner/.
  • Loading branch information
wgtdkp committed Jul 15, 2024
1 parent 6a5cddb commit d9ab095
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/java/commissioner.i
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
#include <commissioner/commissioner.hpp>
%}

%include <std_string.i>
%include <std_shared_ptr.i>
%include <std_string.i>
%include <std_vector.i>
%include <stl.i>
%include <typemaps.i>
Expand All @@ -63,6 +63,7 @@
%apply signed char { uint8_t };
%apply const signed char & { const uint8_t & };
%template(ByteArray) std::vector<uint8_t>;

// Override the typemap of `uint8_t`.
%apply unsigned char { uint8_t };
%apply const unsigned char & { const uint8_t & };
Expand Down Expand Up @@ -140,7 +141,6 @@ namespace commissioner {
%ignore Commissioner::GetPendingDataset(Handler<PendingOperationalDataset> aHandler, uint16_t aDatasetFlags);
%ignore Commissioner::SetPendingDataset(ErrorHandler aHandler, const PendingOperationalDataset &aPendingDataset);
%ignore Commissioner::SetSecurePendingDataset(ErrorHandler aHandler,
const std::string & aPbbrAddr,
uint32_t aMaxRetrievalTimer,
const PendingOperationalDataset &aDataset);
%ignore Commissioner::CommandReenroll(ErrorHandler aHandler, const std::string &aDstAddr);
Expand All @@ -164,7 +164,6 @@ namespace commissioner {
uint16_t aScanDuration,
const std::string &aDstAddr);
%ignore Commissioner::RegisterMulticastListener(Handler<uint8_t> aHandler,
const std::string & aPbbrAddr,
const std::vector<std::string> &aMulticastAddrList,
uint32_t aTimeout);
%ignore Commissioner::RequestToken(Handler<ByteArray> aHandler, const std::string &aAddr, uint16_t aPort);
Expand All @@ -179,6 +178,8 @@ namespace commissioner {
%ignore operator!=(const Error &aError, const ErrorCode &aErrorCode);
%ignore operator==(const ErrorCode &aErrorCode, const Error &aError);
%ignore operator!=(const ErrorCode &aErrorCode, const Error &aError);
%ignore PrintTo(const Error &aError, std::ostream *os);
%ignore PrintTo(ErrorCode aErrorCode, std::ostream *os);
}
}

Expand Down

0 comments on commit d9ab095

Please sign in to comment.