if ( DesignChoiceConstants.PAGE_BREAK_BEFORE_AUTO .equals( pageBreakBefore ) && groupLevel == 0 ) { if ( isTopLevelListing( ) ) { int startGroupLevel = rset.getStartingGroupLevel( ); if ( startGroupLevel > 0 ) { needPageBreak = true; } } }
	protected void handlePageBreakBeforeOfGroup( )	{		boolean needPageBreak = false;				GroupDesign groupDesign = (GroupDesign) design;		if ( groupDesign != null )		{			String pageBreakBefore = groupDesign.getPageBreakBefore( );			int groupLevel = groupDesign.getGroupLevel( );			if ( DesignChoiceConstants.PAGE_BREAK_BEFORE_ALWAYS					.equals( pageBreakBefore ) )			{				needPageBreak = true;			}			if ( DesignChoiceConstants.PAGE_BREAK_BEFORE_ALWAYS_EXCLUDING_FIRST					.equals( pageBreakBefore ) )			{				if ( rset.getStartingGroupLevel( ) > groupLevel )				{					needPageBreak = true;				}			}			if ( DesignChoiceConstants.PAGE_BREAK_BEFORE_AUTO					.equals( pageBreakBefore )					&& groupLevel == 0 )			{				if ( isTopLevelListing( ) )				{					int startGroupLevel = rset.getStartingGroupLevel( );					if ( startGroupLevel > 0 )					{						needPageBreak = true;					}				}			}			if ( needPageBreak )			{				content.getStyle( ).setProperty(						IStyle.STYLE_PAGE_BREAK_BEFORE, IStyle.ALWAYS_VALUE );			}		}	}