16#include <peak/dll_interface/peak_dll_interface_util.hpp>
74 std::string
URL()
const;
195 std::shared_ptr<class Port>
ParentPort()
const;
198 friend ClassCreator<PortURL>;
202 std::weak_ptr<Port> m_parentPort;
218 : m_backendHandle(portUrlHandle)
219 , m_parentPort(parentPort)
224 return QueryRawInformationFromCInterfaceFunction([&](int32_t* dataType, uint8_t* buffer,
size_t* bufferSize) {
231 return QueryStringFromCInterfaceFunction([&](
char* url,
size_t* urlSize) {
246 return QueryStringFromCInterfaceFunction([&](
char* fileName,
size_t* fileNameSize) {
253 return QueryNumericFromCInterfaceFunction<uint64_t>([&](uint64_t* fileRegisterAddress) {
260 return QueryNumericFromCInterfaceFunction<uint64_t>([&](uint64_t* fileSize) {
267 return QueryNumericArrayFromCInterfaceFunction<uint8_t>([&](uint8_t* fileSha1Hash,
size_t* fileSha1HashSize) {
274 return QueryNumericFromCInterfaceFunction<int32_t>([&](int32_t* fileVersionMajor) {
281 return QueryNumericFromCInterfaceFunction<int32_t>([&](int32_t* fileVersionMinor) {
288 return QueryNumericFromCInterfaceFunction<int32_t>([&](int32_t* fileVersionSubminor) {
295 return QueryNumericFromCInterfaceFunction<int32_t>([&](int32_t* fileSchemaVersionMajor) {
302 return QueryNumericFromCInterfaceFunction<int32_t>([&](int32_t* fileSchemaVersionMinor) {
309 return m_parentPort.lock();
314 std::string entryString;
318 entryString =
"Local";
322 entryString =
"HTTP";
326 entryString =
"File";
330 entryString =
"Custom";
PortURL(PortURL &&other)=delete
int32_t FileSchemaVersionMajor() const
Returns the file schema major version.
Definition peak_port_url.hpp:293
PortURL(const PortURL &other)=delete
int32_t FileSchemaVersionMinor() const
Returns the file schema minor version.
Definition peak_port_url.hpp:300
RawInformation Info(int32_t infoCommand) const
Delivers information based on the given GenTL info command.
Definition peak_port_url.hpp:222
std::string URL() const
Returns the URL.
Definition peak_port_url.hpp:229
PortURL & operator=(PortURL &&other)=delete
int32_t FileVersionMinor() const
Returns the file major version.
Definition peak_port_url.hpp:279
int32_t FileVersionMajor() const
Returns the file major version.
Definition peak_port_url.hpp:272
uint64_t FileRegisterAddress() const
Returns the file register address.
Definition peak_port_url.hpp:251
std::string FileName() const
Returns the file name.
Definition peak_port_url.hpp:244
uint64_t FileSize() const
Returns the file size.
Definition peak_port_url.hpp:258
int32_t FileVersionSubminor() const
Returns the file subminor version.
Definition peak_port_url.hpp:286
PortURLScheme Scheme() const
Returns the scheme.
Definition peak_port_url.hpp:236
std::vector< uint8_t > FileSHA1Hash() const
Returns the file SHA1 hash.
Definition peak_port_url.hpp:265
std::shared_ptr< class Port > ParentPort() const
Returns the parent port.
Definition peak_port_url.hpp:307
PortURL & operator=(const PortURL &other)=delete
@ File
Definition peak_buffer.hpp:47
@ Custom
Definition peak_buffer.hpp:56
The "core" namespace contains the direct GenAPI and GenTL wrapper.
Definition peak_buffer.hpp:34
std::string ToString(BufferPayloadType entry)
Definition peak_buffer.hpp:557
PortURLScheme
Possible URL schemes for the port.
Definition peak_port_url.hpp:36
@ File
Definition peak_port_url.hpp:39
@ HTTP
Definition peak_port_url.hpp:38
@ Local
Definition peak_port_url.hpp:37
@ Custom
Definition peak_port_url.hpp:41
The "peak" namespace directly contains convenience functionality like the DeviceManager as well as th...
Definition peak_dynamic_loader.h:33
PEAK_C_API PEAK_PortURL_GetScheme(PEAK_PORT_URL_HANDLE portUrlHandle, PEAK_PORT_URL_SCHEME *scheme)
Asks the given port URL for its scheme.
struct PEAK_PORT_URL * PEAK_PORT_URL_HANDLE
Definition peak_backend.h:473
PEAK_C_API PEAK_PortURL_GetURL(PEAK_PORT_URL_HANDLE portUrlHandle, char *url, size_t *urlSize)
Asks the given port URL for its URL string.
PEAK_C_API PEAK_PortURL_GetFileVersionMinor(PEAK_PORT_URL_HANDLE portUrlHandle, int32_t *fileVersionMinor)
Asks the given port URL for the minor component of its file version.
PEAK_C_API PEAK_PortURL_GetFileVersionMajor(PEAK_PORT_URL_HANDLE portUrlHandle, int32_t *fileVersionMajor)
Asks the given port URL for the major component of its file version.
PEAK_C_API PEAK_PortURL_GetFileName(PEAK_PORT_URL_HANDLE portUrlHandle, char *fileName, size_t *fileNameSize)
Asks the given port URL for its file name.
PEAK_C_API PEAK_PortURL_GetFileRegisterAddress(PEAK_PORT_URL_HANDLE portUrlHandle, uint64_t *fileRegisterAddress)
Asks the given port URL for its file register address.
int32_t PEAK_PORT_URL_SCHEME
Definition peak_backend.h:329
PEAK_C_API PEAK_PortURL_GetFileSize(PEAK_PORT_URL_HANDLE portUrlHandle, uint64_t *fileSize)
Asks the given port URL for its file size.
PEAK_C_API PEAK_PortURL_GetFileVersionSubminor(PEAK_PORT_URL_HANDLE portUrlHandle, int32_t *fileVersionSubminor)
Asks the given port URL for the subminor component of its file version.
PEAK_C_API PEAK_PortURL_GetInfo(PEAK_PORT_URL_HANDLE portUrlHandle, int32_t infoCommand, int32_t *infoDataType, uint8_t *info, size_t *infoSize)
Asks the given port URL for an information based on a specific command.
PEAK_C_API PEAK_PortURL_GetFileSHA1Hash(PEAK_PORT_URL_HANDLE portUrlHandle, uint8_t *fileSha1Hash, size_t *fileSha1HashSize)
Asks the given port URL for its file SHA1 hash.
#define PEAK_C_ABI_PREFIX
Definition peak_dll_defines.h:16