콘텐츠로 이동
무료 평가 시작

pdcomm::GemFormattedProgramExecutionSnapshot

클래스

장비의 정형 프로그램(formatted program) 실행 상태를 담은 불변 사본입니다.

class GemFormattedProgramExecutionSnapshot

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

formattedProgramExecutionSnapshot()으로 얻습니다. 실행한 프로그램의 사본과 애플리케이션 상세 정보 바이트를 포함해 내용을 모두 소유하므로, 이후 상태가 바뀌거나 끝점이 소멸한 뒤에도 유효합니다.

참고

  • 이동 전용(move-only) RAII 래퍼입니다. 조회 함수는 동시에 실행될 수 있지만, 소멸은 조회 함수와 경합해서는 안 됩니다. 빈 스냅숏에서 조회 함수를 호출하면 PDCOMM_INVALID_ARGUMENT를 담은 pdcomm::Error를 던집니다.

멤버

GemFormattedProgramExecutionSnapshot

생성자

네이티브 핸들을 소유하지 않는 빈 스냅숏을 만듭니다.

GemFormattedProgramExecutionSnapshot() noexcept = default

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

GemFormattedProgramExecutionSnapshot

생성자

other가 소유한 네이티브 핸들의 소유권을 넘겨받습니다.

GemFormattedProgramExecutionSnapshot(GemFormattedProgramExecutionSnapshot &&other) noexcept

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

매개변수

이름설명
other원본 래퍼입니다. 호출 후 비게 됩니다.

GemFormattedProgramExecutionSnapshot

생성자

복사할 수 없습니다. 래퍼가 네이티브 핸들을 단독으로 소유합니다.

GemFormattedProgramExecutionSnapshot(const GemFormattedProgramExecutionSnapshot &) = delete

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

applicationDetail

메서드

completeFormattedProgramExecution()에 전달한 상세 정보 바이트를 복사합니다.

std::vector<uint8_t> applicationDetail() const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

상세 정보 바이트입니다. 보고된 것이 없으면 비어 있습니다.

참고

  • 예외 pdcomm::Error: 빈 스냅숏이면 PDCOMM_INVALID_ARGUMENT입니다.

commandCode

메서드

실행한 프로그램의 명령 하나의 CCODE를 반환합니다.

SecsItem commandCode(size_t commandIndex) const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

매개변수

이름설명
commandIndex0부터 시작하는 명령 위치입니다.

반환값

독립적으로 소유되는 아이템입니다.

참고

  • 예외 pdcomm::Error: 실행이 없으면 PDCOMM_INVALID_STATE, 인덱스가 잘못되면 PDCOMM_OUT_OF_RANGE입니다.

commandInfo

메서드

실행한 프로그램의 명령 하나를 설명합니다.

GemFormattedProgramExecutionCommandInfo commandInfo(size_t commandIndex) const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

매개변수

이름설명
commandIndex0부터 시작하는 명령 위치입니다. GemFormattedProgramExecutionInfo::commandCount보다 작아야 합니다.

반환값

파라미터 수와 CCODE 형식입니다.

참고

  • 예외 pdcomm::Error: 실행이 없으면 PDCOMM_INVALID_STATE, 인덱스가 잘못되면 PDCOMM_OUT_OF_RANGE입니다.

info

메서드

스냅숏에 담긴 실행 상태를 반환합니다.

GemFormattedProgramExecutionInfo info() const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

상태, 대기 중인 동작, 시험 실행(dry-run)과 애플리케이션 보고 데이터, 진행 상황입니다.

참고

  • 예외 pdcomm::Error: 빈 스냅숏이면 PDCOMM_INVALID_ARGUMENT입니다.

model

메서드

실행한 프로그램의 MDLN을 복사합니다.

std::string model() const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

모델 텍스트입니다.

참고

  • 예외 pdcomm::Error: 실행이 없으면 PDCOMM_INVALID_STATE입니다.

nativeHandle

메서드

읽기 전용 C API 호출에 쓸 수 있도록 소유한 네이티브 핸들을 반환합니다.

const PdcommGemFormattedProgramExecutionSnapshotHandle *nativeHandle() const noexcept

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

핸들입니다. 빈 스냅숏이면 nullptr입니다. 소유권은 이 래퍼에 남습니다.

operator bool

메서드

래퍼가 네이티브 스냅숏을 소유하는지 알려 줍니다.

explicit operator bool() const noexcept

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

스냅숏을 소유하면 true입니다.

operator=

메서드

현재 핸들을 해제한 뒤 other가 소유한 핸들의 소유권을 넘겨받습니다.

GemFormattedProgramExecutionSnapshot &operator=(GemFormattedProgramExecutionSnapshot &&other) noexcept

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

매개변수

이름설명
other원본 래퍼입니다. 호출 후 비게 됩니다.

반환값

이 래퍼입니다.

operator=

메서드

복사 대입을 할 수 없습니다. 래퍼가 네이티브 핸들을 단독으로 소유합니다.

GemFormattedProgramExecutionSnapshot &operator=(const GemFormattedProgramExecutionSnapshot &) = delete

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

parameter

메서드

실행한 프로그램의 명령 하나에서 PPARM 하나를 반환합니다.

SecsItem parameter(size_t commandIndex, size_t parameterIndex) const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

매개변수

이름설명
commandIndex0부터 시작하는 명령 위치입니다.
parameterIndex0부터 시작하는 파라미터 위치입니다.

반환값

독립적으로 소유되는 아이템입니다.

참고

  • 예외 pdcomm::Error: 실행이 없으면 PDCOMM_INVALID_STATE, 인덱스가 잘못되면 PDCOMM_OUT_OF_RANGE입니다.

programId

메서드

실행한 프로그램의 PPID를 반환합니다.

SecsItem programId() const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

독립적으로 소유되는 ASCII 또는 Binary 아이템입니다.

참고

  • 예외 pdcomm::Error: 실행이 없으면 PDCOMM_INVALID_STATE입니다.

softwareRevision

메서드

실행한 프로그램의 SOFTREV를 복사합니다.

std::string softwareRevision() const

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

반환값

소프트웨어 리비전 텍스트입니다.

참고

  • 예외 pdcomm::Error: 실행이 없으면 PDCOMM_INVALID_STATE입니다.

~GemFormattedProgramExecutionSnapshot

메서드

pdcomm_gem_formatted_program_execution_snapshot_destroy()로 네이티브 핸들을 해제합니다.

~GemFormattedProgramExecutionSnapshot()

선언 위치: #include <pdcomm_gem_formatted_program_executions.hpp>

빈 스냅숏은 아무것도 해제하지 않습니다.