# wso2wsf::NeethiPolicy Class Reference
[Neethi Policy]

class NeethiPolicy Defines a policy object that can be used to provide WS-Policy information. This is a wrapper to the XML policy advertisement used in WS-Security, WS-Reliable Messaging etc. More...

`#include <NeethiPolicy.h>`

List of all members.

## Public Member Functions
neethi_policy_t * | getNeethiPolicy ()
void | setNeethiPolicy (neethi_policy_t *policy)
WSF_EXTERN | NeethiPolicy (std::string file_name)
WSF_EXTERN | NeethiPolicy (OMElement *element)
virtual | ~NeethiPolicy ()
WSF_EXTERN bool | setName (std::string name)
WSF_EXTERN std::string | getName ()
WSF_EXTERN bool | setId (std::string id)
WSF_EXTERN std::string | getId ()

## Detailed Description

class NeethiPolicy Defines a policy object that can be used to provide WS-Policy information. This is a wrapper to the XML policy advertisement used in WS-Security, WS-Reliable Messaging etc.

## Constructor & Destructor Documentation

WSF_EXTERN wso2wsf::NeethiPolicy::NeethiPolicy | ( | std::string | file_name | ) |

Constructor for the NeethiPolicy Class. Accepts the policy file name as the argument.

Parameters:

  | file_name | file name.

WSF_EXTERN wso2wsf::NeethiPolicy::NeethiPolicy | ( | OMElement * | element | ) |

Constructor for NeethiPolicy Class. Accepts an OMElement representing the WS-Policy XML

Parameters:

  | element | OM element which is the root of WS-Policy XML.

virtual wso2wsf::NeethiPolicy::~NeethiPolicy | ( |  | ) | `[virtual]`

Destructor for the NeethiPolicy class.

## Member Function Documentation

WSF_EXTERN std::string wso2wsf::NeethiPolicy::getId | ( |  | ) |

Gets policy id.

Returns:
  policy id as string.

WSF_EXTERN std::string wso2wsf::NeethiPolicy::getName | ( |  | ) |

Gets policy name.

Returns:
  policy name as string.

neethi_policy_t* wso2wsf::NeethiPolicy::getNeethiPolicy | ( |  | ) |

Method to get the reference to the neethi_policy struct.

Returns:
  reference to the neethi_policy struct.

WSF_EXTERN bool wso2wsf::NeethiPolicy::setId | ( | std::string | id | ) |

Sets policy id.

Parameters:

  | id | id to set.

Returns:
  true if successful, false otherwise.

WSF_EXTERN bool wso2wsf::NeethiPolicy::setName | ( | std::string | name | ) |

Sets policy name.

Parameters:

  | name | name to set.

Returns:
  true if successful, false otherwise.

void wso2wsf::NeethiPolicy::setNeethiPolicy | ( | neethi_policy_t * | policy | ) |

Method to set the reference to the neethi_policy struct.

Parameters:

  | policy | reference to the neethi_policy struct.

The documentation for this class was generated from the following file:

- NeethiPolicy.h