Author: cziegeler
Date: Tue Oct 19 12:58:15 2004
New Revision: 55091
Modified:
cocoon/whiteboard/ecmplus/src/java/org/apache/cocoon/components/container/RoleManager.java
Log:
Cosmetics
Modified:
cocoon/whiteboard/ecmplus/src/java/org/apache/cocoon/components/container/RoleManager.java
==============================================================================
---
cocoon/whiteboard/ecmplus/src/java/org/apache/cocoon/components/container/RoleManager.java
(original)
+++
cocoon/whiteboard/ecmplus/src/java/org/apache/cocoon/components/container/RoleManager.java
Tue Oct 19 12:58:15 2004
@@ -76,8 +76,7 @@
public final String getRoleForName( final String shorthandName ) {
final String role = (String)this.shorthands.get( shorthandName );
- if( null == role && null != this.parent )
- {
+ if( null == role && null != this.parent ) {
return this.parent.getRoleForName( shorthandName );
}
@@ -102,8 +101,7 @@
public final String getDefaultClassNameForRole( final String role ) {
final String className = (String)this.classNames.get( role );
- if( null == className && null != this.parent )
- {
+ if( null == className && null != this.parent ) {
return this.parent.getDefaultClassNameForRole( role );
}
@@ -124,8 +122,8 @@
*/
public final String getDefaultClassNameForHint( final String role,
final String shorthand ) {
- if( getLogger().isDebugEnabled() ) {
- getLogger().debug( "looking up hintmap for role " + role );
+ if( this.getLogger().isDebugEnabled() ) {
+ this.getLogger().debug( "looking up hintmap for role " + role );
}
final Map hintMap = (Map)this.hintClassNames.get( role );
@@ -133,22 +131,20 @@
if( null == hintMap ) {
if( null != this.parent ) {
return this.parent.getDefaultClassNameForHint( role, shorthand
);
- } else {
- return "";
- }
+ }
+ return "";
}
- if( getLogger().isDebugEnabled() ) {
- getLogger().debug( "looking up classname for hint " + shorthand );
+ if( this.getLogger().isDebugEnabled() ) {
+ this.getLogger().debug( "looking up classname for hint " +
shorthand );
}
final String s = ( String ) hintMap.get( shorthand );
if( s == null && null != this.parent ) {
return this.parent.getDefaultClassNameForHint( role, shorthand );
- } else {
- return s;
- }
+ }
+ return s;
}
/**
@@ -169,8 +165,7 @@
for( int i = 0; i < roles.length; i++ ) {
final String name = roles[ i ].getAttribute( "name" );
final String shorthand = roles[ i ].getAttribute( "shorthand" );
- final String defaultClassName =
- roles[ i ].getAttribute( "default-class", null );
+ final String defaultClassName = roles[ i ].getAttribute(
"default-class", null );
shorts.put( shorthand, name );
@@ -187,18 +182,18 @@
String className = hints[ j ].getAttribute( "class"
).trim();
hintMap.put( shortHand, className );
- if( getLogger().isDebugEnabled() ) {
- getLogger().debug( "Adding hint type " + shortHand +
- " associated with role " + name +
- " and class " + className );
+ if( this.getLogger().isDebugEnabled() ) {
+ this.getLogger().debug( "Adding hint type " +
shortHand +
+ " associated with role " +
name +
+ " and class " + className );
}
}
hintclasses.put( name, Collections.unmodifiableMap( hintMap )
);
}
- if( getLogger().isDebugEnabled() ) {
- getLogger().debug( "added Role " + name + " with shorthand " +
+ if( this.getLogger().isDebugEnabled() ) {
+ this.getLogger().debug( "added Role " + name + " with
shorthand " +
shorthand + " for " + defaultClassName );
}
}