Skip to content

Commit 02a1913

Browse files
committed
Merge remote-tracking branch 'origin/objgetname'
Ticket #3: New function PWR_ObjGetSizeName
2 parents 5500e6b + c5bcac4 commit 02a1913

2 files changed

Lines changed: 19 additions & 1 deletion

File tree

ChangeLog.tex

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
The following list contains changes to the community Power API specification version 2.1
2+
\begin{itemize}
3+
\item{PWR_ObjGetSizeOfName - New function added that allows the user to get the size of buffer required to successfully call PWR_ObjGetName for a given object.}
4+
5+
\end{itemize}
6+
7+
18
The following list contains changes to version 2.0 of the specification.
29
\begin{itemize}
310
\item{PWR_StatusCreate - Added a context input parameter and clarified that statuses are cleared when used as an input to a function, therefore they should be checked prior to reuse, and caution should be taken when sharing statuses between threads.}

Common.tex

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ \section{Hierarchy Navigation Functions}\label{sec:Navigation}
123123
%=============================================================================%
124124
%int PWR_ObjGetName( PWR_Obj object, char* dest, size_t len );
125125
\begin{prototype}{ObjGetName}
126-
\longdescription{The \texttt{PWR_ObjGetName} function copies the name of the specified object into the user provided buffer. See page \pageref{func:CntxtGetObjByName} to get the object based on the unique name using \texttt{PWR_CntxtGetObjByName}.}
126+
\longdescription{The \texttt{PWR_ObjGetName} function copies the name of the specified object into the user provided buffer. See page \pageref{func:CntxtGetObjByName} to get the object based on the unique name using \texttt{PWR_CntxtGetObjByName}.}
127127
\returntype{int}
128128
\parameter{PWR_Obj object} {\pInput} {The object that the user wishes to determine the name of.}
129129
\parameter{char* dest} {\pInput} {The address of the user provided buffer.}
@@ -132,6 +132,17 @@ \section{Hierarchy Navigation Functions}\label{sec:Navigation}
132132
\returnval{PWR_RET_WARN_TRUNC} {Call succeeded, but the length of object name was longer than the provided buffer and the name was truncated.}
133133
\returnval{PWR_RET_FAILURE} {Upon FAILURE.}
134134
\end{prototype}
135+
%=============================================================================%
136+
%int PWR_ObjGetSizeOfName( PWR_Obj object, size_t len );
137+
\begin{prototype}{ObjGetSizeOfName}
138+
\longdescription{The \texttt{PWR_ObjGetSizeOfName} returns the length of an object's name. The len parameter will contain the length of the name of the specified object including any string terminators upon return. See page \pageref{func:CntxtGetObjByName} to get the object based on the unique name using \texttt{PWR_CntxtGetObjByName}.}
139+
\returntype{int}
140+
\parameter{PWR_Obj object} {\pInput} {The object that the user wishes to determine the name of.}
141+
\parameter{size_t* len} {\pInputOutput} {The length of the user provided buffer.}
142+
\returnval{PWR_RET_SUCCESS} {Upon SUCCESS, the len parameter will contain the size of buffer required to successfully call \texttt{PWR_ObjGetName}, including terminating null byte.}
143+
\returnval{PWR_RET_FAILURE} {Upon FAILURE.}
144+
\end{prototype}
145+
135146
%==============================================================================%
136147
%int PWR_ObjGetParent( PWR_Obj object, PWR_Obj* parent );
137148
\begin{prototype}{ObjGetParent}

0 commit comments

Comments
 (0)