### org.jfree.layouting.input.style.selectors.conditions

# Class CSSConditionFactory

- `java.lang.Object`
- - `org.jfree.layouting.input.style.selectors.conditions.CSSConditionFactory`

Implemented Interfaces:
  ConditionFactory

`public class CSSConditionFactory`
`extends java.lang.Object`
`implements ConditionFactory`

Creation-Date: 24.11.2005, 19:43:13

Author:
  Thomas Morgner

  ## Constructor Summary

  `CSSConditionFactory()`

  ## Method Summary

  `CombinatorCondition`

  `createAndCondition(Condition first, Condition second)`
    Creates an and condition

  `AttributeCondition`

  `createAttributeCondition(String localName, String namespaceURI, boolean specified, String value)`
    Creates an attribute condition

  `AttributeCondition`

  `createBeginHyphenAttributeCondition(String localName, String namespaceURI, boolean specified, String value)`
    Creates a "begin hyphen" attribute condition

  `AttributeCondition`

  `createClassCondition(String namespaceURI, String value)`
    Creates a class condition

  `ContentCondition`

  `createContentCondition(String data)`
    Creates a content condition

  `AttributeCondition`

  `createIdCondition(String value)`
    Creates an id condition

  `LangCondition`

  `createLangCondition(String lang)`
    Creates a lang condition

  `NegativeCondition`

  `createNegativeCondition(Condition condition)`
    Creates a negative condition

  `AttributeCondition`

  `createOneOfAttributeCondition(String localName, String namespaceURI, boolean specified, String value)`
    Creates a "one of" attribute condition

  `Condition`

  `createOnlyChildCondition()`
    Creates a "only one" child condition

  `Condition`

  `createOnlyTypeCondition()`
    Creates a "only one" type condition

  `CombinatorCondition`

  `createOrCondition(Condition first, Condition second)`
    Creates an or condition

  `PositionalCondition`

  `createPositionalCondition(int position, boolean typeNode, boolean type)`
    Creates a positional condition

  `AttributeCondition`

  `createPseudoClassCondition(String namespaceURI, String value)`
    Creates a pseudo class condition

## Constructor Details

### CSSConditionFactory

    public CSSConditionFactory()

## Method Details

### createAndCondition

    public CombinatorCondition createAndCondition(Condition first,
                                                  Condition second)
                throws CSSException

> Creates an and condition
> Parameters:
>   `first` - the first condition
>   `second` - the second condition
> Returns:
>   A combinator condition

### createAttributeCondition

    public AttributeCondition createAttributeCondition(String localName,
                                                       String namespaceURI,
                                                       boolean specified,
                                                       String value)
                throws CSSException

> Creates an attribute condition
> Parameters:
>   `localName` - the localName of the attribute
>   `namespaceURI` - the namespace URI of the attribute
>   `specified` - `true` if the attribute must be specified in the document.
>   `value` - the value of this attribute.
> Returns:
>   An attribute condition

### createBeginHyphenAttributeCondition

    public AttributeCondition createBeginHyphenAttributeCondition(String localName,
                                                                  String namespaceURI,
                                                                  boolean specified,
                                                                  String value)
                throws CSSException

> Creates a "begin hyphen" attribute condition
> Parameters:
>   `localName` - the localName of the attribute
>   `namespaceURI` - the namespace URI of the attribute
>   `specified` - `true` if the attribute must be specified in the document.
>   `value` - the value of this attribute.
> Returns:
>   A "begin hyphen" attribute condition

### createClassCondition

    public AttributeCondition createClassCondition(String namespaceURI,
                                                   String value)
                throws CSSException

> Creates a class condition
> Parameters:
>   `namespaceURI` - the namespace URI of the attribute
>   `value` - the name of the class.
> Returns:
>   A class condition

### createContentCondition

    public ContentCondition createContentCondition(String data)
                throws CSSException

> Creates a content condition
> Parameters:
>   `data` - the data in the content
> Returns:
>   A content condition

### createIdCondition

    public AttributeCondition createIdCondition(String value)
                throws CSSException

> Creates an id condition
> Parameters:
>   `value` - the value of the id.
> Returns:
>   An Id condition

### createLangCondition

    public LangCondition createLangCondition(String lang)
                throws CSSException

> Creates a lang condition
> Parameters:
> Returns:
>   A lang condition

### createNegativeCondition

    public NegativeCondition createNegativeCondition(Condition condition)
                throws CSSException

> Creates a negative condition
> Parameters:
>   `condition` - the condition
> Returns:
>   A negative condition

### createOneOfAttributeCondition

    public AttributeCondition createOneOfAttributeCondition(String localName,
                                                            String namespaceURI,
                                                            boolean specified,
                                                            String value)
                throws CSSException

> Creates a "one of" attribute condition
> Parameters:
>   `localName` - the localName of the attribute
>   `namespaceURI` - the namespace URI of the attribute
>   `specified` - `true` if the attribute must be specified in the document.
>   `value` - the value of this attribute.
> Returns:
>   A "one of" attribute condition

### createOnlyChildCondition

    public Condition createOnlyChildCondition()
                throws CSSException

> Creates a "only one" child condition
> Returns:
>   A "only one" child condition

### createOnlyTypeCondition

    public Condition createOnlyTypeCondition()
                throws CSSException

> Creates a "only one" type condition
> Returns:
>   A "only one" type condition

### createOrCondition

    public CombinatorCondition createOrCondition(Condition first,
                                                 Condition second)
                throws CSSException

> Creates an or condition
> Parameters:
>   `first` - the first condition
>   `second` - the second condition
> Returns:
>   A combinator condition

### createPositionalCondition

    public PositionalCondition createPositionalCondition(int position,
                                                         boolean typeNode,
                                                         boolean type)
                throws CSSException

> Creates a positional condition
> Parameters:
>   `position` - the position of the node in the list.
>   `typeNode` - `true` if the list should contain only nodes of the same type (element, text node, ...).
>   `type` - `true` true if the list should contain only nodes of the same node (for element, same localName and same namespaceURI).
> Returns:
>   A positional condition

### createPseudoClassCondition

    public AttributeCondition createPseudoClassCondition(String namespaceURI,
                                                         String value)
                throws CSSException

> Creates a pseudo class condition
> Parameters:
>   `namespaceURI` - the namespace URI of the attribute
>   `value` - the name of the pseudo class
> Returns:
>   A pseudo class condition