本文整理汇总了Java中net.sf.jasperreports.engine.type.BandTypeEnum.DETAIL属性的典型用法代码示例。如果您正苦于以下问题:Java BandTypeEnum.DETAIL属性的具体用法?Java BandTypeEnum.DETAIL怎么用?Java BandTypeEnum.DETAIL使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类net.sf.jasperreports.engine.type.BandTypeEnum
的用法示例。
在下文中一共展示了BandTypeEnum.DETAIL属性的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createCommand
@Override
protected Command createCommand() {
List<Object> bands = editor.getSelectionCache().getSelectionModelForType(MBand.class);
if (bands.isEmpty()) return null;
MBand firstBand = (MBand)bands.get(0);
JSSCompoundCommand cmd = new JSSCompoundCommand(firstBand);
for(Object obj : bands){
MBand bandNode = (MBand)obj;
if ( bandNode.getBandType() == BandTypeEnum.GROUP_FOOTER || bandNode.getBandType() == BandTypeEnum.GROUP_HEADER){
cmd.add(new ReorderBandCommandByRelativeIndex((MBandGroupFooter) bandNode, 1));
} else if (bandNode.getBandType() == BandTypeEnum.DETAIL) {
cmd.add(new ReorderBandCommandByRelativeIndex(bandNode, (MReport) bandNode.getParent(), 1));
}
}
return cmd.isEmpty() ? null : cmd;
}
示例2: createCommand
@Override
protected Command createCommand() {
List<Object> bands = editor.getSelectionCache().getSelectionModelForType(MBand.class);
if (bands.isEmpty()) return null;
MBand firstBand = (MBand)bands.get(0);
JSSCompoundCommand cmd = new JSSCompoundCommand(firstBand);
for(Object obj : bands){
MBand bandNode = (MBand)obj;
if ( bandNode.getBandType() == BandTypeEnum.GROUP_FOOTER || bandNode.getBandType() == BandTypeEnum.GROUP_HEADER){
cmd.add(new ReorderBandCommandByRelativeIndex((MBandGroupFooter) bandNode, -1));
} else if (bandNode.getBandType() == BandTypeEnum.DETAIL) {
cmd.add(new ReorderBandCommandByRelativeIndex(bandNode, (MReport) bandNode.getParent(), -1));
}
}
return cmd.isEmpty() ? null : cmd;
}
示例3: JasperDesign
@SuppressWarnings("deprecation")
public JasperDesign(JasperReportsContext context)
{
setMainDataset(new JRDesignDataset(context, true));
detailSection = new JRDesignSection(new JROrigin(BandTypeEnum.DETAIL));
}
示例4: isColumnBand
protected boolean isColumnBand()
{
BandTypeEnum bandType = origin.getBandTypeValue();
return
bandType == BandTypeEnum.GROUP_HEADER
|| bandType == BandTypeEnum.GROUP_FOOTER
|| bandType == BandTypeEnum.DETAIL;
}
示例5: setElementsType
/**
* Inspect the loaded model to search the detail band and all it's content to the type cache map
*/
private void setElementsType(){
//Search for the detail band
if (defaultReport == null || defaultReport.getChildren().isEmpty() || !(defaultReport instanceof MRoot)) return;
for(INode node : defaultReport.getChildren().get(0).getChildren()){
if (node instanceof MBand){
MBand band = (MBand)node;
if (band.getBandType() == BandTypeEnum.DETAIL){
addAll(band);
break;
}
}
}
}
示例6: searchDetailBand
/**
* Return the detail band of the actually selected template set
*
* @return the model of the detail band or null if it can't be found
*/
private INode searchDetailBand(){
MReport mReport = (MReport)defaultReport.getChildren().get(0);
for(INode child : mReport.getChildren()){
if (child instanceof MBand && child.getValue() != null){
MBand band = (MBand)child;
if (band.getBandType() == BandTypeEnum.DETAIL) return band;
}
}
return null;
}
示例7: getActions
@Override
public Action[] getActions(boolean popup) {
java.util.List<Action> list = new ArrayList<Action>();
list.add( SystemAction.get(PasteAction.class));
list.add( SystemAction.get(RefreshNodes.class));
if (getBand().getOrigin().getBandTypeValue() == BandTypeEnum.BACKGROUND)
{
list.add(SystemAction.get(MaximizeBackgroundAction.class));
}
else
{
list.add(SystemAction.get(MaximizeBandAction.class));
}
if (getBand().getOrigin().getBandTypeValue() == BandTypeEnum.DETAIL)
{
list.add(SystemAction.get(AddAnotherDetailBandAction.class));
}
if (group != null)
{
list.add( null );
list.add( SystemAction.get(MoveGroupUpAction.class));
list.add( SystemAction.get(MoveGroupDownAction.class));
list.add( DeleteGroupAction.getInstance() );
list.add(null);
list.add( SystemAction.get(AddAnotherGroupHeaderBandAction.class));
list.add( SystemAction.get(AddAnotherGroupFooterBandAction.class));
}
list.add( DeleteBandAction.getInstance());
return list.toArray(new Action[list.size()]);
}
示例8: isMultiBand
public static boolean isMultiBand(MBand mband) {
return mband.getBandType() == BandTypeEnum.DETAIL || mband.getBandType() == BandTypeEnum.GROUP_HEADER
|| mband.getBandType() == BandTypeEnum.GROUP_FOOTER;
}