Java 类net.sf.jasperreports.engine.JRHyperlinkHelper 实例源码

项目:jasperreports    文件:JRFillPieDataset.java   
@Override
protected void customEvaluate(JRCalculator calculator) throws JRExpressionEvalException
{
    if (pieSeries != null && pieSeries.length > 0)
    {
        for(int i = 0; i < pieSeries.length; i++)
        {
            pieSeries[i].evaluate(calculator);
        }
    }

    otherKey = (String)calculator.evaluate(getOtherKeyExpression());
    otherLabel = (String)calculator.evaluate(getOtherLabelExpression());

    if (!JRHyperlinkHelper.isEmpty(getOtherSectionHyperlink()))
    {
        evaluateOtherSectionHyperlink(calculator);
    }       
}
项目:jasperreports    文件:JRBaseTextField.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        evaluationTimeValue = EvaluationTimeEnum.getByValue(evaluationTime);
    }
}
项目:jasperreports    文件:JRDesignTextField.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        evaluationTimeValue = EvaluationTimeEnum.getByValue(evaluationTime);
    }
}
项目:jasperreports    文件:JRBaseChart.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        evaluationTimeValue = EvaluationTimeEnum.getByValue(evaluationTime);

        if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_1_3)
        {
            legendPositionValue = EdgeEnum.getByValue(legendPosition);
            titlePositionValue = EdgeEnum.getByValue(titlePosition);
            showLegend = Boolean.valueOf(isShowLegend);
        }
        else
        {
            legendPositionValue = EdgeEnum.getByValue(legendPositionByte);
            titlePositionValue = EdgeEnum.getByValue(titlePositionByte);

            legendPositionByte = null;
            titlePositionByte = null;
        }

    }
}
项目:jasperreports    文件:JRBasePrintHyperlink.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }
}
项目:jasperreports    文件:JRBaseHyperlink.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }
}
项目:jasperreports    文件:JRBaseImage.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        horizontalAlignmentValue = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getByValue(horizontalAlignment);
        verticalAlignmentValue = net.sf.jasperreports.engine.type.VerticalAlignEnum.getByValue(verticalAlignment);
        scaleImageValue = ScaleImageEnum.getByValue(scaleImage);
        onErrorTypeValue = OnErrorTypeEnum.getByValue(onErrorType);
        evaluationTimeValue = EvaluationTimeEnum.getByValue(evaluationTime);

        horizontalAlignment = null;
        verticalAlignment = null;
        scaleImage = null;
    }

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_6_0_2)
    {
        horizontalImageAlign = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getHorizontalImageAlignEnum(horizontalAlignmentValue);
        verticalImageAlign = net.sf.jasperreports.engine.type.VerticalAlignEnum.getVerticalImageAlignEnum(verticalAlignmentValue);

        horizontalAlignmentValue = null;
        verticalAlignmentValue = null;
    }
}
项目:jasperreports    文件:JRDesignChart.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        evaluationTimeValue = EvaluationTimeEnum.getByValue(evaluationTime);
        if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_1_3)
        {
            legendPositionValue = EdgeEnum.getByValue(legendPosition);
            titlePositionValue = EdgeEnum.getByValue(titlePosition);
            showLegend = Boolean.valueOf(isShowLegend);
        }
        else
        {
            legendPositionValue = EdgeEnum.getByValue(legendPositionByte);
            titlePositionValue = EdgeEnum.getByValue(titlePositionByte);

            legendPositionByte = null;
            titlePositionByte = null;
        }

    }
}
项目:jasperreports    文件:JRDesignImage.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        horizontalAlignmentValue = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getByValue(horizontalAlignment);
        verticalAlignmentValue = net.sf.jasperreports.engine.type.VerticalAlignEnum.getByValue(verticalAlignment);
        scaleImageValue = ScaleImageEnum.getByValue(scaleImage);
        onErrorTypeValue = OnErrorTypeEnum.getByValue(onErrorType);
        evaluationTimeValue = EvaluationTimeEnum.getByValue(evaluationTime);

        horizontalAlignment = null;
        verticalAlignment = null;
        scaleImage = null;
    }

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_6_0_2)
    {
        horizontalImageAlign = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getHorizontalImageAlignEnum(horizontalAlignmentValue);
        verticalImageAlign = net.sf.jasperreports.engine.type.VerticalAlignEnum.getVerticalImageAlignEnum(verticalAlignmentValue);

        horizontalAlignmentValue = null;
        verticalAlignmentValue = null;
    }
}
项目:jasperreports    文件:JRTemplateImage.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        horizontalAlignmentValue = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getByValue(horizontalAlignment);
        verticalAlignmentValue = net.sf.jasperreports.engine.type.VerticalAlignEnum.getByValue(verticalAlignment);
        scaleImageValue = ScaleImageEnum.getByValue(scaleImage);
        onErrorTypeValue = OnErrorTypeEnum.getByValue(onErrorType);

        horizontalAlignment = null;
        verticalAlignment = null;
        scaleImage = null;
    }

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_6_0_2)
    {
        horizontalImageAlign = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getHorizontalImageAlignEnum(horizontalAlignmentValue);
        verticalImageAlign = net.sf.jasperreports.engine.type.VerticalAlignEnum.getVerticalImageAlignEnum(verticalAlignmentValue);

        horizontalAlignmentValue = null;
        verticalAlignmentValue = null;
    }
}
项目:jasperreports    文件:JRFillXyzSeries.java   
public boolean hasItemHyperlinks()
{
    return !JRHyperlinkHelper.isEmpty(getItemHyperlink()); 
}
项目:jasperreports    文件:JRFillTimeSeries.java   
public boolean hasItemHyperlink()
{
    return !JRHyperlinkHelper.isEmpty(getItemHyperlink()); 
}
项目:jasperreports    文件:JRFillPieSeries.java   
public boolean hasSectionHyperlinks()
{
    return !JRHyperlinkHelper.isEmpty(getSectionHyperlink()); 
}
项目:jasperreports    文件:JRFillTimePeriodSeries.java   
public boolean hasItemHyperlink()
{
    return !JRHyperlinkHelper.isEmpty(getItemHyperlink()); 
}
项目:jasperreports    文件:JRFillCategorySeries.java   
public boolean hasItemHyperlinks()
{
    return !JRHyperlinkHelper.isEmpty(getItemHyperlink()); 
}
项目:jasperreports    文件:JRFillHighLowDataset.java   
public boolean hasItemHyperlink()
{
    return !JRHyperlinkHelper.isEmpty(getItemHyperlink()); 
}
项目:jasperreports    文件:JRFillPieDataset.java   
@Override
public Dataset getCustomDataset()
{
    double total = 0;
    List<Double> sortedValues = new ArrayList<Double>();
    for(Number nv: values.values())
    {
        double dvalue = nv.doubleValue();
        total += dvalue;
        sortedValues.add(dvalue);
    }
    Collections.sort(sortedValues);

    Double minValue = null;
    if (getMinPercentage() != null && getMinPercentage().intValue() >= 0 && getMinPercentage().intValue() <= 100)//FIXMENOW why intValue?
    {
        minValue = new Double((getMinPercentage().doubleValue() * total) / 100);
    }
    if (getMaxCount() != null && getMaxCount().intValue() >= 0 && getMaxCount().intValue() <= values.size())
    {
        Double minValue2 = sortedValues.get(sortedValues.size() - getMaxCount().intValue());
        minValue = minValue != null && minValue.doubleValue() > minValue2.doubleValue() ? minValue : minValue2;  
    }

    int otherCount = 0;
    Comparable<?> lastOtherKey = null;
    Number lastOtherValue = null;
    double otherTotal = 0;

    DefaultPieDataset dataset = new DefaultPieDataset();
    for(Iterator<Comparable<?>> it = values.keySet().iterator(); it.hasNext();)
    {
        Comparable<?> key = it.next();
        Number value = values.get(key);

        if (
            minValue == null
            || value.doubleValue() >= minValue.doubleValue() 
            )
        {
            dataset.setValue(key, value);
        }
        else
        {
            otherCount++;
            lastOtherKey = key;
            lastOtherValue = value;
            otherTotal += value.doubleValue();
        }
    }
    if (otherCount == 1)
    {
        dataset.setValue(lastOtherKey, lastOtherValue);
    }
    else if (otherCount > 1)
    {
        otherKey = otherKey == null ? "Other" : otherKey;
        dataset.setValue(otherKey, new Double(otherTotal));
        labels.put(otherKey, otherLabel);

        if (!JRHyperlinkHelper.isEmpty(getOtherSectionHyperlink()))
        {
            sectionHyperlinks.put(otherKey, otherSectionHyperlink);
        }       
    }

    return dataset;
}
项目:jasperreports    文件:JRFillXySeries.java   
public boolean hasItemHyperlinks()
{
    return !JRHyperlinkHelper.isEmpty(getItemHyperlink()); 
}
项目:jasperreports    文件:JRBaseChart.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(this);
}
项目:jasperreports    文件:JRBaseChart.java   
@Override
public byte getHyperlinkTarget()
{
    return JRHyperlinkHelper.getHyperlinkTarget(this);
}
项目:jasperreports    文件:JRBasePrintHyperlink.java   
@Override
public HyperlinkTargetEnum getHyperlinkTargetValue()
{
    return JRHyperlinkHelper.getHyperlinkTargetValue(getLinkTarget());
}
项目:jasperreports    文件:JRBasePrintHyperlink.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(getLinkType());
}
项目:jasperreports    文件:JRBasePrintHyperlink.java   
@Override
public void setHyperlinkTarget(HyperlinkTargetEnum hyperlinkTarget)
{
    setLinkTarget(JRHyperlinkHelper.getLinkTarget(hyperlinkTarget));
}
项目:jasperreports    文件:JRBasePrintHyperlink.java   
@Override
public void setHyperlinkType(HyperlinkTypeEnum hyperlinkType)
{
    setLinkType(JRHyperlinkHelper.getLinkType(hyperlinkType));
}
项目:jasperreports    文件:JRBasePrintText.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(getLinkType());
}
项目:jasperreports    文件:JRBasePrintText.java   
@Override
public void setHyperlinkType(HyperlinkTypeEnum hyperlinkType)
{
    setLinkType(JRHyperlinkHelper.getLinkType(hyperlinkType));
}
项目:jasperreports    文件:JRBasePrintText.java   
@Override
public HyperlinkTargetEnum getHyperlinkTargetValue()
{
    return JRHyperlinkHelper.getHyperlinkTargetValue(getLinkTarget());
}
项目:jasperreports    文件:JRBasePrintText.java   
@Override
public void setHyperlinkTarget(HyperlinkTargetEnum hyperlinkTarget)
{
    setLinkTarget(JRHyperlinkHelper.getLinkTarget(hyperlinkTarget));
}
项目:jasperreports    文件:JRBasePrintText.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        horizontalAlignmentValue = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getByValue(horizontalAlignment);
        verticalAlignmentValue = net.sf.jasperreports.engine.type.VerticalAlignEnum.getByValue(verticalAlignment);
        rotationValue = RotationEnum.getByValue(rotation);
        runDirectionValue = RunDirectionEnum.getByValue(runDirection);
        lineSpacingValue = LineSpacingEnum.getByValue(lineSpacing);

        horizontalAlignment = null;
        verticalAlignment = null;
        rotation = null;
        lineSpacing = null;
    }

    if (isStyledText != null)
    {
        markup = isStyledText.booleanValue() ? JRCommonText.MARKUP_STYLED_TEXT : JRCommonText.MARKUP_NONE;
        isStyledText = null;
    }

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (paragraph == null)
    {
        paragraph = new JRBaseParagraph(this);
        paragraph.setLineSpacing(lineSpacingValue);
        lineSpacingValue = null;
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_5_5_2)
    {
        fontsize = fontSize == null ? null : fontSize.floatValue();

        fontSize = null;
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_6_0_2)
    {
        horizontalTextAlign = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getHorizontalTextAlignEnum(horizontalAlignmentValue);
        verticalTextAlign = net.sf.jasperreports.engine.type.VerticalAlignEnum.getVerticalTextAlignEnum(verticalAlignmentValue);

        horizontalAlignmentValue = null;
        verticalAlignmentValue = null;
    }
}
项目:jasperreports    文件:JRBaseTextField.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(this);
}
项目:jasperreports    文件:JRBaseTextField.java   
@Override
public byte getHyperlinkTarget()
{
    return JRHyperlinkHelper.getHyperlinkTarget(this);
}
项目:jasperreports    文件:JRBasePrintImage.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(getLinkType());
}
项目:jasperreports    文件:JRBasePrintImage.java   
@Override
public void setHyperlinkType(HyperlinkTypeEnum hyperlinkType)
{
    setLinkType(JRHyperlinkHelper.getLinkType(hyperlinkType));
}
项目:jasperreports    文件:JRBasePrintImage.java   
@Override
public HyperlinkTargetEnum getHyperlinkTargetValue()
{
    return JRHyperlinkHelper.getHyperlinkTargetValue(getLinkTarget());
}
项目:jasperreports    文件:JRBasePrintImage.java   
@Override
public void setHyperlinkTarget(HyperlinkTargetEnum hyperlinkTarget)
{
    setLinkTarget(JRHyperlinkHelper.getLinkTarget(hyperlinkTarget));
}
项目:jasperreports    文件:JRBasePrintImage.java   
@SuppressWarnings("deprecation")
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
{
    in.defaultReadObject();

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_3_7_2)
    {
        horizontalAlignmentValue = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getByValue(horizontalAlignment);
        verticalAlignmentValue = net.sf.jasperreports.engine.type.VerticalAlignEnum.getByValue(verticalAlignment);
        scaleImageValue = ScaleImageEnum.getByValue(scaleImage);
        onErrorTypeValue = OnErrorTypeEnum.getByValue(onErrorType);

        horizontalAlignment = null;
        verticalAlignment = null;
        scaleImage = null;
    }

    if (linkType == null)
    {
         linkType = JRHyperlinkHelper.getLinkType(HyperlinkTypeEnum.getByValue(hyperlinkType));
    }

    if (linkTarget == null)
    {
         linkTarget = JRHyperlinkHelper.getLinkTarget(HyperlinkTargetEnum.getByValue(hyperlinkTarget));
    }

    if (renderer != null && renderable == null)
    {
        if (renderer instanceof Renderable)
        {
            renderable = (Renderable)renderer;
        }
        else
        {
            renderable = net.sf.jasperreports.engine.RenderableUtil.getWrappingRenderable(renderer);
        }
    }

    if (PSEUDO_SERIAL_VERSION_UID < JRConstants.PSEUDO_SERIAL_VERSION_UID_6_0_2)
    {
        horizontalImageAlign = net.sf.jasperreports.engine.type.HorizontalAlignEnum.getHorizontalImageAlignEnum(horizontalAlignmentValue);
        verticalImageAlign = net.sf.jasperreports.engine.type.VerticalAlignEnum.getVerticalImageAlignEnum(verticalAlignmentValue);

        horizontalAlignmentValue = null;
        verticalAlignmentValue = null;
    }
}
项目:jasperreports    文件:JRBaseHyperlink.java   
@Override
public byte getHyperlinkTarget()
{
    return JRHyperlinkHelper.getHyperlinkTarget(this);
}
项目:jasperreports    文件:JRBaseHyperlink.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(this);
}
项目:jasperreports    文件:JRBaseImage.java   
@Override
public HyperlinkTypeEnum getHyperlinkTypeValue()
{
    return JRHyperlinkHelper.getHyperlinkTypeValue(this);
}
项目:jasperreports    文件:JRBaseImage.java   
@Override
public byte getHyperlinkTarget()
{
    return JRHyperlinkHelper.getHyperlinkTarget(this);
}