Sophie

Sophie

distrib > Mandriva > current > x86_64 > by-pkgid > 3736f276bb1ccfbcee6cb2d27b25d981 > files > 740

openscap-devel-0.5.7-1mdv2010.1.x86_64.rpm

\hypertarget{structcpe__lang__model}{
\section{cpe\_\-lang\_\-model Struct Reference}
\label{structcpe__lang__model}\index{cpe\_\-lang\_\-model@{cpe\_\-lang\_\-model}}
}


CPE platform specification.  


{\ttfamily \#include $<$cpelang\_\-priv.h$>$}\subsection*{Public Member Functions}
\begin{Indent}{\bf Parse functions}\par
{\em \label{_amgrp55bde346b0631e090bfc4a3be713ee4c}
Functions for parsing structures from XML.

Return value is new structure filled by content of XML file represented by XML reader or import source structure. Structure needs to be freed by the caller. }\begin{DoxyCompactItemize}
\item 
struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$ \hyperlink{group__CPELangPrivate_gab01dcd52258398ecee496bea1681a8eb}{cpe\_\-lang\_\-model\_\-parse\_\-xml} (const struct \hyperlink{structoscap__import__source}{oscap\_\-import\_\-source} $\ast$source)
\begin{DoxyCompactList}\small\item\em Function for parsing XML CPE language file. \item\end{DoxyCompactList}\item 
struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$ \hyperlink{group__CPELangPrivate_gaabe5beb378e8ef716e90c174ea8957c8}{cpe\_\-lang\_\-model\_\-parse} (xmlTextReaderPtr reader)
\begin{DoxyCompactList}\small\item\em Parse function for CPE Lang model. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}{\bf Export functions}\par
{\em \label{_amgrp5713b34587ba18c5a4561b737b639ae5}
Functions for export structures to XML by XML writer.

Exported structures need to be freed by the caller. }\begin{DoxyCompactItemize}
\item 
void \hyperlink{group__CPELangPrivate_gab4a84e46014c142d88bca5b2b28151a1}{cpe\_\-lang\_\-model\_\-export\_\-xml} (const struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$spec, struct \hyperlink{structoscap__export__target}{oscap\_\-export\_\-target} $\ast$target)
\begin{DoxyCompactList}\small\item\em Function for export CPE language model to XML. \item\end{DoxyCompactList}\item 
void \hyperlink{group__CPELangPrivate_ga58fe65219194db588c1f35c8bfa473b1}{cpe\_\-lang\_\-export} (const struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$spec, xmlTextWriterPtr writer)
\begin{DoxyCompactList}\small\item\em Function for export CPE language top element. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}{\bf Get functions}\par
{\em \label{_amgrpc2ac1eb4de8ec5add5567cbae2f237e5}
Functions for getting attributes from CVE model structures.

Return value is pointer to structure's member. Do not free unless you null the pointer in the structure. Use remove function otherwise. }\begin{DoxyCompactItemize}
\item 
\hypertarget{group__cpelang_ga8c3446147158e606b9d02ccd33020d8a}{
const char $\ast$ \hyperlink{group__cpelang_ga8c3446147158e606b9d02ccd33020d8a}{cpe\_\-lang\_\-model\_\-get\_\-ns\_\-prefix} (const struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$item)}
\label{group__cpelang_ga8c3446147158e606b9d02ccd33020d8a}

\begin{DoxyCompactList}\small\item\em \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} function to get namespace prefix \item\end{DoxyCompactList}\item 
\hypertarget{group__cpelang_gaa5e9009c4b979291e110552c8e8a31b1}{
struct \hyperlink{structcpe__platform__iterator}{cpe\_\-platform\_\-iterator} $\ast$ \hyperlink{group__cpelang_gaa5e9009c4b979291e110552c8e8a31b1}{cpe\_\-lang\_\-model\_\-get\_\-platforms} (const struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$item)}
\label{group__cpelang_gaa5e9009c4b979291e110552c8e8a31b1}

\begin{DoxyCompactList}\small\item\em \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} function to get CPE platforms \item\end{DoxyCompactList}\item 
\hypertarget{group__cpelang_ga90b91aecc0f9f8255a32b1fe00de1234}{
struct \hyperlink{structxml__metadata__iterator}{xml\_\-metadata\_\-iterator} $\ast$ \hyperlink{group__cpelang_ga90b91aecc0f9f8255a32b1fe00de1234}{cpe\_\-lang\_\-model\_\-get\_\-xmlns} (const struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$item)}
\label{group__cpelang_ga90b91aecc0f9f8255a32b1fe00de1234}

\begin{DoxyCompactList}\small\item\em \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} function to get xmlns attribute \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}{\bf Add functions}\par
{\em \label{_amgrpaabced06c8a2e8c15954ce4b1e334884}
Get XML namespace from CPE lang model

Functions to add member to list. Return value is true if added succesfuly or false in case of error. }\begin{DoxyCompactItemize}
\item 
\hypertarget{group__cpelang_ga563eeb9702f9c93df5a25998e9a39600}{
bool \hyperlink{group__cpelang_ga563eeb9702f9c93df5a25998e9a39600}{cpe\_\-lang\_\-model\_\-add\_\-platform} (struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$lang, struct \hyperlink{structcpe__platform}{cpe\_\-platform} $\ast$platform)}
\label{group__cpelang_ga563eeb9702f9c93df5a25998e9a39600}

\begin{DoxyCompactList}\small\item\em Add platform to CPE lang model. \item\end{DoxyCompactList}\item 
\hypertarget{group__cpelang_gab31bfb6288d13667166acab4947db1ff}{
bool \hyperlink{group__cpelang_gab31bfb6288d13667166acab4947db1ff}{cpe\_\-lang\_\-model\_\-add\_\-xml} (struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$lang, struct \hyperlink{structxml__metadata}{xml\_\-metadata} $\ast$xml)}
\label{group__cpelang_gab31bfb6288d13667166acab4947db1ff}

\begin{DoxyCompactList}\small\item\em Add xml metadata to CPE lang model. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}{\bf New functions}\par
{\em \label{_amgrp73a4128f20867fa23ebb2e75e58922df}
Constructors of CVE model structures.

Free function returns new empty allocated structure. If returns non NULL it need to be freed by the caller. }\begin{DoxyCompactItemize}
\item 
\hypertarget{group__cpelang_gab38c9e5fb94f6cbb806cb02d4d24bf51}{
struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$ \hyperlink{group__cpelang_gab38c9e5fb94f6cbb806cb02d4d24bf51}{cpe\_\-lang\_\-model\_\-new} (void)}
\label{group__cpelang_gab38c9e5fb94f6cbb806cb02d4d24bf51}

\begin{DoxyCompactList}\small\item\em Constructor of CPE Language model. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}{\bf Set functions}\par
{\em \label{_amgrp8b7ecf2f4bd25da1aae981677901d55d}
Set functions assign values to members of structures except lists.

For lists use add functions. Parameters of set functions are duplicated in memory and need to be freed by caller. }\begin{DoxyCompactItemize}
\item 
\hypertarget{group__cpelang_ga24d19a5cfb7d414053f8a5e99a4e6b5a}{
bool \hyperlink{group__cpelang_ga24d19a5cfb7d414053f8a5e99a4e6b5a}{cpe\_\-lang\_\-model\_\-set\_\-ns\_\-prefix} (struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$model, const char $\ast$new\_\-prefix)}
\label{group__cpelang_ga24d19a5cfb7d414053f8a5e99a4e6b5a}

\begin{DoxyCompactList}\small\item\em Set ns\_\-prefix to CPE lang model. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\begin{Indent}{\bf Free functions}\par
{\em \label{_amgrp237dd65bc76b7de56066830910ced6ed}
Destructors of CVE model structures.

Functions free structures with all members recursively. For simple deletion of entity use remove functions. }\begin{DoxyCompactItemize}
\item 
\hypertarget{group__cpelang_ga6a4e8a7210b76078bb6ac8bc9f3be0a7}{
void \hyperlink{group__cpelang_ga6a4e8a7210b76078bb6ac8bc9f3be0a7}{cpe\_\-lang\_\-model\_\-free} (struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$platformspec)}
\label{group__cpelang_ga6a4e8a7210b76078bb6ac8bc9f3be0a7}

\begin{DoxyCompactList}\small\item\em Free function of CPE test expression. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\end{Indent}
\subsection*{Data Fields}
\begin{DoxyCompactItemize}
\item 
\hypertarget{structcpe__lang__model_a674e8e479068d89f10f989a1c3a6bbd6}{
struct \hyperlink{structxml__metadata}{xml\_\-metadata} {\bfseries xml}}
\label{structcpe__lang__model_a674e8e479068d89f10f989a1c3a6bbd6}

\item 
\hypertarget{structcpe__lang__model_a6df6463440310f5a1a8ad3a3bb0d649b}{
struct \hyperlink{structoscap__list}{oscap\_\-list} $\ast$ {\bfseries xmlns}}
\label{structcpe__lang__model_a6df6463440310f5a1a8ad3a3bb0d649b}

\item 
\hypertarget{structcpe__lang__model_ae1f9858e6d045b7c78930082378b9c2a}{
char $\ast$ {\bfseries ns\_\-prefix}}
\label{structcpe__lang__model_ae1f9858e6d045b7c78930082378b9c2a}

\item 
\hypertarget{structcpe__lang__model_a97841b6e17ef67a3a9d3eba7699812e4}{
struct \hyperlink{structoscap__list}{oscap\_\-list} $\ast$ {\bfseries platforms}}
\label{structcpe__lang__model_a97841b6e17ef67a3a9d3eba7699812e4}

\item 
\hypertarget{structcpe__lang__model_aede4a5217e69d18e2a71757d163e6bbd}{
struct \hyperlink{structoscap__htable}{oscap\_\-htable} $\ast$ {\bfseries item}}
\label{structcpe__lang__model_aede4a5217e69d18e2a71757d163e6bbd}

\end{DoxyCompactItemize}
\subsection*{Other functions}
\label{_amgrpb175402ebe89f00c62233c5453c5a243}
 \begin{DoxyCompactItemize}
\item 
const char $\ast$ \hyperlink{group__cpelang_gabf469c1ab5798bb321e6c89ffb4b6e9d}{cpe\_\-lang\_\-model\_\-supported} (void)
\begin{DoxyCompactList}\small\item\em Get supported version of CPE language XML. \item\end{DoxyCompactList}\item 
\hypertarget{group__cpelang_ga092a153b42c0b5565a2c22eebf79874d}{
struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$ \hyperlink{group__cpelang_ga092a153b42c0b5565a2c22eebf79874d}{cpe\_\-lang\_\-model\_\-import} (const struct \hyperlink{structoscap__import__source}{oscap\_\-import\_\-source} $\ast$source)}
\label{group__cpelang_ga092a153b42c0b5565a2c22eebf79874d}

\begin{DoxyCompactList}\small\item\em Load CPE language model from a XML document. \item\end{DoxyCompactList}\item 
void \hyperlink{group__cpelang_gade703f4a7cf45cefa351f975a5fed5da}{cpe\_\-lang\_\-model\_\-export} (const struct \hyperlink{structcpe__lang__model}{cpe\_\-lang\_\-model} $\ast$spec, struct \hyperlink{structoscap__export__target}{oscap\_\-export\_\-target} $\ast$target)
\begin{DoxyCompactList}\small\item\em Write the lang\_\-model to a file. \item\end{DoxyCompactList}\item 
bool \hyperlink{group__cpelang_ga087bb45387925a51ae6be052320327c2}{cpe\_\-platform\_\-match\_\-cpe} (struct \hyperlink{structcpe__name}{cpe\_\-name} $\ast$$\ast$cpe, size\_\-t n, const struct \hyperlink{structcpe__platform}{cpe\_\-platform} $\ast$platform)
\begin{DoxyCompactList}\small\item\em Function to match cpe in platform. \item\end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
CPE platform specification. 

The documentation for this struct was generated from the following files:\begin{DoxyCompactItemize}
\item 
/home/pvrabec/openscap/openscap-\/0.5.7/src/CPE/\hyperlink{cpelang__priv_8c}{cpelang\_\-priv.c}\item 
/home/pvrabec/openscap/openscap-\/0.5.7/src/CPE/\hyperlink{cpelang__priv_8h}{cpelang\_\-priv.h}\item 
/home/pvrabec/openscap/openscap-\/0.5.7/src/CPE/public/\hyperlink{cpelang_8h}{cpelang.h}\end{DoxyCompactItemize}