ch.qos.logback.core.joran.spi
Class Pattern

java.lang.Object
  extended by ch.qos.logback.core.joran.spi.Pattern

public class Pattern
extends java.lang.Object

A pattern is used to designate XML elements in a document.

For more information see http://logback.qos.ch/manual/onJoran.html#pattern

Author:
Ceki Gülcü

Constructor Summary
Pattern()
           
Pattern(java.util.List<java.lang.String> list)
           
Pattern(java.lang.String p)
          Build a pattern from a string.
 
Method Summary
 java.lang.Object clone()
           
 boolean equals(java.lang.Object o)
           
 java.lang.String get(int i)
           
 java.util.List<java.lang.String> getCopyOfPartList()
           
 int getPrefixMatchLength(Pattern p)
          Returns the number of "prefix" components that this pattern has in common with the pattern p passed as parameter.
 int getTailMatchLength(Pattern p)
          Returns the number of "tail" components that this pattern has in common with the pattern p passed as parameter.
 int hashCode()
           
 boolean isContained(Pattern p)
           
 java.lang.String peekLast()
           
 void pop()
           
 void push(java.lang.String s)
           
 int size()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Pattern

public Pattern()

Pattern

public Pattern(java.util.List<java.lang.String> list)

Pattern

public Pattern(java.lang.String p)
Build a pattern from a string. Note that "/x" is considered equivalent to "x" and to "x/"

Method Detail

getCopyOfPartList

public java.util.List<java.lang.String> getCopyOfPartList()

clone

public java.lang.Object clone()
Overrides:
clone in class java.lang.Object

push

public void push(java.lang.String s)

size

public int size()

get

public java.lang.String get(int i)

pop

public void pop()

peekLast

public java.lang.String peekLast()

getTailMatchLength

public int getTailMatchLength(Pattern p)
Returns the number of "tail" components that this pattern has in common with the pattern p passed as parameter. By "tail" components we mean the components at the end of the pattern.


isContained

public boolean isContained(Pattern p)

getPrefixMatchLength

public int getPrefixMatchLength(Pattern p)
Returns the number of "prefix" components that this pattern has in common with the pattern p passed as parameter. By "prefix" components we mean the components at the beginning of the pattern.


equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object