org.springframework.data.repository.query.parser

## Class Part

- java.lang.Object
- - org.springframework.data.repository.query.parser.Part

    public class Part
    extends Object

A single part of a method name that has to be transformed into a query part. The actual transformation is defined by a `Part.Type` that is determined from inspecting the given part. The query part can then be looked up via `getProperty()`.

Author:
  Oliver Gierke, Martin Baumgartner, Jens Schauder

### Nested Class Summary

Nested Classes
`static class` `Part.IgnoreCaseType` The various types of ignore case that are supported.
`static class` `Part.Type` The type of a method name part.

### Constructor Summary

Constructors
Constructor and Description
`Part(String source, Class<?> clazz)` Creates a new `Part` from the given method name part, the `Class` the part originates from and the start parameter index.
`Part(String source, Class<?> clazz, boolean alwaysIgnoreCase)` Creates a new `Part` from the given method name part, the `Class` the part originates from and the start parameter index.

### Method Summary

All Methods Instance Methods Concrete Methods
`boolean` `equals(Object o)`
`int` `getNumberOfArguments()` Returns how many method parameters are bound by this part.
`PropertyPath` `getProperty()`
`Part.Type` `getType()`
`int` `hashCode()`
`Part.IgnoreCaseType` `shouldIgnoreCase()` Returns whether the `PropertyPath` referenced should be matched ignoring case.
`String` `toString()`

### Methods inherited from class java.lang.Object

`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### Part

    public Part(String source,
                Class<?> clazz)

Creates a new `Part` from the given method name part, the `Class` the part originates from and the start parameter index.

Parameters:
  `source` - must not be null.
  `clazz` - must not be null.

#### Part

    public Part(String source,
                Class<?> clazz,
                boolean alwaysIgnoreCase)

Creates a new `Part` from the given method name part, the `Class` the part originates from and the start parameter index.

Parameters:
  `source` - must not be null.
  `clazz` - must not be null.
  `alwaysIgnoreCase` -

### Method Detail

#### getNumberOfArguments

    public int getNumberOfArguments()

Returns how many method parameters are bound by this part.

Returns:

#### getProperty

    public PropertyPath getProperty()

Returns:
  the propertyPath

#### getType

    public Part.Type getType()

Returns:
  the type

#### shouldIgnoreCase

    public Part.IgnoreCaseType shouldIgnoreCase()

Returns whether the `PropertyPath` referenced should be matched ignoring case.

Returns:

#### equals

    public boolean equals(Object o)

Overrides:
  `equals` in class `Object`

#### hashCode

    public int hashCode()

Overrides:
  `hashCode` in class `Object`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`