Main Page | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

cr-attr-sel.h File Reference

#include <stdio.h>
#include <glib.h>
#include "cr-utils.h"
#include "cr-parsing-location.h"
#include "cr-string.h"

Go to the source code of this file.

Data Structures

struct  _CRAttrSel

Typedefs

typedef _CRAttrSel CRAttrSel

Enumerations

enum  AttrMatchWay {
  NO_MATCH = 0, SET, EQUALS, INCLUDES,
  DASHMATCH
}

Functions

CRAttrSelcr_attr_sel_new (void)
 The constructor of CRAttrSel.
enum CRStatus cr_attr_sel_append_attr_sel (CRAttrSel *a_this, CRAttrSel *a_new)
 Appends an attribute selector to the current list of attribute selectors represented by a_this.
enum CRStatus cr_attr_sel_prepend_attr_sel (CRAttrSel *a_this, CRAttrSel *a_attr_sel)
 Prepends an attribute selector to the list of attributes selector represented by a_this.
guchar * cr_attr_sel_to_string (CRAttrSel *a_this)
void cr_attr_sel_dump (CRAttrSel *a_this, FILE *a_fp)
 Dumps the current instance of CRAttrSel to a file.
void cr_attr_sel_destroy (CRAttrSel *a_this)
 Destroys the current instance of CRAttrSel.


Typedef Documentation

typedef struct _CRAttrSel CRAttrSel
 

Definition at line 37 of file cr-attr-sel.h.

Referenced by cr_additional_sel_set_attr_sel(), cr_attr_sel_append_attr_sel(), cr_attr_sel_destroy(), cr_attr_sel_dump(), cr_attr_sel_new(), cr_attr_sel_prepend_attr_sel(), and cr_attr_sel_to_string().


Enumeration Type Documentation

enum AttrMatchWay
 

Enumeration values:
NO_MATCH 
SET 
EQUALS 
INCLUDES 
DASHMATCH 

Definition at line 39 of file cr-attr-sel.h.


Function Documentation

enum CRStatus cr_attr_sel_append_attr_sel CRAttrSel a_this,
CRAttrSel a_attr_sel
 

Appends an attribute selector to the current list of attribute selectors represented by a_this.

Parameters:
a_this the this pointer of the current instance of CRAttrSel.
a_attr_sel selector to append.
Returns:
CR_OK upon successfull completion, an error code otherwise.

Definition at line 59 of file cr-attr-sel.c.

References CR_BAD_PARAM_ERROR, CRAttrSel, _CRAttrSel::next, and _CRAttrSel::prev.

void cr_attr_sel_destroy CRAttrSel a_this  ) 
 

Destroys the current instance of CRAttrSel.

Frees all the fields if they are non null.

Parameters:
a_this the "this pointer" of the current instance of CRAttrSel.

Definition at line 198 of file cr-attr-sel.c.

References cr_string_destroy(), CRAttrSel, _CRAttrSel::name, _CRAttrSel::next, and _CRAttrSel::value.

Referenced by cr_additional_sel_destroy(), and cr_additional_sel_set_attr_sel().

void cr_attr_sel_dump CRAttrSel a_this,
FILE *  a_fp
 

Dumps the current instance of CRAttrSel to a file.

Parameters:
a_this the "this pointer" of the current instance of CRAttrSel.
a_fp the destination file.

Definition at line 176 of file cr-attr-sel.c.

References cr_attr_sel_to_string(), and CRAttrSel.

CRAttrSel* cr_attr_sel_new void   ) 
 

The constructor of CRAttrSel.

Returns:
the newly allocated instance of CRAttrSel.

Definition at line 40 of file cr-attr-sel.c.

References CRAttrSel.

enum CRStatus cr_attr_sel_prepend_attr_sel CRAttrSel a_this,
CRAttrSel a_attr_sel
 

Prepends an attribute selector to the list of attributes selector represented by a_this.

Parameters:
a_this the "this pointer" of the current instance of CRAttrSel.
a_attr_sel the attribute selector to append.
Returns:
CR_OK upon successfull completion, an error code otherwise.

Definition at line 86 of file cr-attr-sel.c.

References CR_BAD_PARAM_ERROR, CRAttrSel, _CRAttrSel::next, and _CRAttrSel::prev.

guchar* cr_attr_sel_to_string CRAttrSel a_this  ) 
 

Definition at line 99 of file cr-attr-sel.c.

References CRAttrSel, DASHMATCH, EQUALS, INCLUDES, name, _CRAttrSel::name, _CRAttrSel::next, _CRAttrSel::prev, SET, _CRString::stryng, and _CRAttrSel::value.

Referenced by cr_additional_sel_one_to_string(), cr_additional_sel_to_string(), and cr_attr_sel_dump().


Generated on Fri Oct 29 08:29:13 2004 for Libcroco by  doxygen 1.3.9.1