Critter (Hyperic HQ Plugin API)
Keywords: org.hyperic.hq.grouping.Critter interface

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.hyperic.hq.grouping
Interface Critter

All Known Implementing Classes:
  ProtoCritterType.ProtoCritter, ResourceTypeCritterType.ResourceTypeCritter

    public interface Critter

A `Critter` is a criteria, able to aid in composing complex SQL.

Method Summary
`void` | `bindSqlParams(CritterTranslationContext ctx, org.hibernate.Query q)` Bind any SQL parameters which were previously returned as part of getSql().
`java.lang.String` | `getConfig()` Returns a localized description of how the Critter is configured.
`CritterType` | `getCritterType()` Returns the `CritterType` associated with this Critter
`java.util.List` | `getProps()` Get a list of `CritterProps`s which are the current values set for this critter.
`java.lang.String` | `getSql(CritterTranslationContext ctx, java.lang.String resourceAlias)` Get a SQL segment, suitable for placement within a where clause.
`java.lang.String` | `getSqlJoins(CritterTranslationContext ctx, java.lang.String resourceAlias)` Get additional SQL specifying joins requierd by the critter The result of this method is run through `CritterTranslationContext.escapeSql(String)` which will turn all references delimited by '@' into unique identifiers.

Method Detail

### getProps

    java.util.List getProps()

  Get a list of `CritterProps`s which are the current values set for this critter.

### getSql

    java.lang.String getSql(CritterTranslationContext ctx,
                            java.lang.String resourceAlias)

  Get a SQL segment, suitable for placement within a where clause. The result of this method is run through `CritterTranslationContext.escapeSql(String)`, which will turn all references delimited '@' into unique identifiers.

  Parameters:
    `resourceAlias` - The SQL alias for the `Resource`

### getSqlJoins

    java.lang.String getSqlJoins(CritterTranslationContext ctx,
                                 java.lang.String resourceAlias)

  Get additional SQL specifying joins requierd by the critter The result of this method is run through `CritterTranslationContext.escapeSql(String)` which will turn all references delimited by '@' into unique identifiers.

### bindSqlParams

    void bindSqlParams(CritterTranslationContext ctx,
                       org.hibernate.Query q)

  Bind any SQL parameters which were previously returned as part of getSql(). The implementor of this method will likely need to use `CritterTranslationContext.escape(String)` to bind to variables which match the references returned from getSql, etc.

### getCritterType

    CritterType getCritterType()

  Returns the `CritterType` associated with this Critter

### getConfig

    java.lang.String getConfig()

  Returns a localized description of how the Critter is configured. Should work in the following layout: If all of the following criteria are met: - Resource name matches 'web.*' - Resource type is Apache 2.0 (or...) If any of the following criteria are met: - Resource is a child of 'my.platform' and of type 'Fileserver File' - Resource has been modified in the last 2 days

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2006 Hyperic, Inc. support@hyperic.net, All Rights Reserved.