本文整理汇总了Java中org.jfree.chart.imagemap.ToolTipTagFragmentGenerator类的典型用法代码示例。如果您正苦于以下问题:Java ToolTipTagFragmentGenerator类的具体用法?Java ToolTipTagFragmentGenerator怎么用?Java ToolTipTagFragmentGenerator使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ToolTipTagFragmentGenerator类属于org.jfree.chart.imagemap包,在下文中一共展示了ToolTipTagFragmentGenerator类的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getImageMapAreaTag
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Returns an HTML image map tag tag for this entity.
*
* @param toolTipTagFragmentGenerator the generator for tooltip fragment.
* @param urlTagFragmentGenerator the generator for the URL fragment.
*
* @return The HTML tag.
*/
public String getImageMapAreaTag(ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
StringBuffer tag = new StringBuffer();
boolean hasURL = (this.urlText == null ? false : !this.urlText.equals(""));
boolean hasToolTip = (this.toolTipText == null ? false : !this.toolTipText.equals(""));
if (hasURL || hasToolTip) {
tag.append("<AREA SHAPE=\"" + getShapeType() + "\"" + " COORDS=\""
+ getShapeCoords() + "\"");
if (hasToolTip) {
tag.append(toolTipTagFragmentGenerator.generateToolTipFragment(this.toolTipText));
}
if (hasURL) {
tag.append(urlTagFragmentGenerator.generateURLFragment(this.urlText));
}
tag.append(">");
}
return tag.toString();
}
示例2: writeImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Writes an image map to an output stream.
*
* @param writer the writer (<code>null</code> not permitted).
* @param name the map name (<code>null</code> not permitted).
* @param info the chart rendering info (<code>null</code> not permitted).
* @param toolTipTagFragmentGenerator the tool tip generator.
* @param urlTagFragmentGenerator the url generator.
*
* @throws IOException if there are any I/O errors.
*/
public static void writeImageMap(PrintWriter writer, String name, ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator)
throws IOException {
writer.println(
ImageMapUtil.getImageMap(
name, info, toolTipTagFragmentGenerator, urlTagFragmentGenerator
)
);
}
示例3: getImageMapAreaTag
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Returns an HTML image map tag for this entity. The returned fragment
* should be <code>XHTML 1.0</code> compliant.
*
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if this entity contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* this entity has a URL).
*
* @return The HTML tag.
*/
public String getImageMapAreaTag(
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
StringBuffer tag = new StringBuffer();
boolean hasURL = (this.urlText == null ? false
: !this.urlText.equals(""));
boolean hasToolTip = (this.toolTipText == null ? false
: !this.toolTipText.equals(""));
if (hasURL || hasToolTip) {
tag.append("<area shape=\"" + getShapeType() + "\"" + " coords=\""
+ getShapeCoords() + "\"");
if (hasToolTip) {
tag.append(toolTipTagFragmentGenerator.generateToolTipFragment(
this.toolTipText));
}
if (hasURL) {
tag.append(urlTagFragmentGenerator.generateURLFragment(
this.urlText));
}
// if there is a tool tip, we expect it to generate the title and
// alt values, so we only add an empty alt if there is no tooltip
if (!hasToolTip) {
tag.append(" alt=\"\"");
}
tag.append("/>");
}
return tag.toString();
}
示例4: getImageMapAreaTag
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Returns an HTML image map tag for this entity. The returned fragment
* should be <code>XHTML 1.0</code> compliant.
*
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if this entity contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* this entity has a URL).
*
* @return The HTML tag.
*/
public String getImageMapAreaTag(
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
StringBuilder tag = new StringBuilder();
boolean hasURL = (this.urlText == null ? false
: !this.urlText.equals(""));
boolean hasToolTip = (this.toolTipText == null ? false
: !this.toolTipText.equals(""));
if (hasURL || hasToolTip) {
tag.append("<area shape=\"").append(getShapeType()).append("\"")
.append(" coords=\"").append(getShapeCoords()).append("\"");
if (hasToolTip) {
tag.append(toolTipTagFragmentGenerator.generateToolTipFragment(
this.toolTipText));
}
if (hasURL) {
tag.append(urlTagFragmentGenerator.generateURLFragment(
this.urlText));
}
else {
tag.append(" nohref=\"nohref\"");
}
// if there is a tool tip, we expect it to generate the title and
// alt values, so we only add an empty alt if there is no tooltip
if (!hasToolTip) {
tag.append(" alt=\"\"");
}
tag.append("/>");
}
return tag.toString();
}
示例5: getImageMapAreaTag
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Returns an HTML image map tag for this entity. The returned fragment
* should be {@code XHTML 1.0} compliant.
*
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text ({@code null} not permitted
* if this entity contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference ({@code null} not permitted if
* this entity has a URL).
*
* @return The HTML tag.
*/
public String getImageMapAreaTag(
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
StringBuilder tag = new StringBuilder();
boolean hasURL = (this.urlText == null ? false
: !this.urlText.equals(""));
boolean hasToolTip = (this.toolTipText == null ? false
: !this.toolTipText.equals(""));
if (hasURL || hasToolTip) {
tag.append("<area shape=\"").append(getShapeType()).append("\"")
.append(" coords=\"").append(getShapeCoords()).append("\"");
if (hasToolTip) {
tag.append(toolTipTagFragmentGenerator.generateToolTipFragment(
this.toolTipText));
}
if (hasURL) {
tag.append(urlTagFragmentGenerator.generateURLFragment(
this.urlText));
}
else {
tag.append(" nohref=\"nohref\"");
}
// if there is a tool tip, we expect it to generate the title and
// alt values, so we only add an empty alt if there is no tooltip
if (!hasToolTip) {
tag.append(" alt=\"\"");
}
tag.append("/>");
}
return tag.toString();
}
示例6: getImageMapAreaTag
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Returns an HTML image map tag for this entity. The returned fragment
* should be <code>XHTML 1.0</code> compliant.
*
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if this entity contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* this entity has a URL).
*
* @return The HTML tag.
*/
public String getImageMapAreaTag(
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
StringBuffer tag = new StringBuffer();
boolean hasURL = (this.urlText == null ? false
: !this.urlText.equals(""));
boolean hasToolTip = (this.toolTipText == null ? false
: !this.toolTipText.equals(""));
if (hasURL || hasToolTip) {
tag.append("<area shape=\"" + getShapeType() + "\"" + " coords=\""
+ getShapeCoords() + "\"");
if (hasToolTip) {
tag.append(toolTipTagFragmentGenerator.generateToolTipFragment(
this.toolTipText));
}
if (hasURL) {
tag.append(urlTagFragmentGenerator.generateURLFragment(
this.urlText));
}
else {
tag.append(" nohref=\"nohref\"");
}
// if there is a tool tip, we expect it to generate the title and
// alt values, so we only add an empty alt if there is no tooltip
if (!hasToolTip) {
tag.append(" alt=\"\"");
}
tag.append("/>");
}
return tag.toString();
}
示例7: getImageMapAreaTag
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Returns an HTML image map tag for this entity. The returned fragment
* should be <code>XHTML 1.0</code> compliant.
*
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if this entity contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* this entity has a URL).
*
* @return The HTML tag.
*/
public String getImageMapAreaTag(
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
StringBuffer tag = new StringBuffer();
boolean hasURL = (this.urlText == null ? false
: !this.urlText.equals(""));
boolean hasToolTip = (this.toolTipText == null ? false
: !this.toolTipText.equals(""));
if (hasURL || hasToolTip) {
tag.append("<area shape=\"").append(getShapeType()).append("\"")
.append(" coords=\"").append(getShapeCoords()).append("\"");
if (hasToolTip) {
tag.append(toolTipTagFragmentGenerator.generateToolTipFragment(
this.toolTipText));
}
if (hasURL) {
tag.append(urlTagFragmentGenerator.generateURLFragment(
this.urlText));
}
else {
tag.append(" nohref=\"nohref\"");
}
// if there is a tool tip, we expect it to generate the title and
// alt values, so we only add an empty alt if there is no tooltip
if (!hasToolTip) {
tag.append(" alt=\"\"");
}
tag.append("/>");
}
return tag.toString();
}
示例8: getImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Creates an HTML image map.
*
* @param name the map name (<code>null</code> not permitted).
* @param info the chart rendering info (<code>null</code> not permitted).
* @param toolTipTagFragmentGenerator the tool tip generator.
* @param urlTagFragmentGenerator the url generator.
*
* @return the map tag.
*/
public static String getImageMap(String name,
ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
return ImageMapUtil.getImageMap(name, info, toolTipTagFragmentGenerator, urlTagFragmentGenerator);
}
示例9: writeImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Writes an image map to the specified writer.
*
* @param writer the writer (<code>null</code> not permitted).
* @param name the map name (<code>null</code> not permitted).
* @param info the chart rendering info (<code>null</code> not permitted).
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if <code>info</code> contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* <code>info</code> contains URLs).
*
* @throws IOException if there are any I/O errors.
*/
public static void writeImageMap(PrintWriter writer, String name,
ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator)
throws IOException {
writer.println(ImageMapUtilities.getImageMap(name, info,
toolTipTagFragmentGenerator, urlTagFragmentGenerator));
}
示例10: getImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Creates an HTML image map. This method maps directly to
* {@link ImageMapUtilities#getImageMap(String, ChartRenderingInfo,
* ToolTipTagFragmentGenerator, URLTagFragmentGenerator)}.
*
* @param name the map name (<code>null</code> not permitted).
* @param info the chart rendering info (<code>null</code> not permitted).
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if <code>info</code> contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* <code>info</code> contains URLs).
*
* @return The map tag.
*/
public static String getImageMap(String name, ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
return ImageMapUtilities.getImageMap(name, info,
toolTipTagFragmentGenerator, urlTagFragmentGenerator);
}
示例11: writeImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Writes an image map to the specified writer.
*
* @param writer the writer (<code>null</code> not permitted).
* @param name the map name (<code>null</code> not permitted).
* @param info the chart rendering info (<code>null</code> not permitted).
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if <code>info</code> contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* <code>info</code> contains URLs).
*
* @throws IOException if there are any I/O errors.
*/
public static void writeImageMap(PrintWriter writer, String name,
ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator)
throws IOException {
writer.println(ImageMapUtilities.getImageMap(name, info,
toolTipTagFragmentGenerator, urlTagFragmentGenerator));
}
示例12: getImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Creates an HTML image map. This method maps directly to
* {@link ImageMapUtilities#getImageMap(String, ChartRenderingInfo,
* ToolTipTagFragmentGenerator, URLTagFragmentGenerator)}.
*
* @param name the map name (<code>null</code> not permitted).
* @param info the chart rendering info (<code>null</code> not permitted).
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text (<code>null</code> not permitted
* if <code>info</code> contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference (<code>null</code> not permitted if
* <code>info</code> contains URLs).
*
* @return The map tag.
*/
public static String getImageMap(String name, ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
return ImageMapUtilities.getImageMap(name, info,
toolTipTagFragmentGenerator, urlTagFragmentGenerator);
}
示例13: writeImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Writes an image map to the specified writer.
*
* @param writer the writer ({@code null} not permitted).
* @param name the map name ({@code null} not permitted).
* @param info the chart rendering info ({@code null} not permitted).
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text ({@code null} not permitted
* if {@code info} contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference ({@code null} not permitted if
* {@code info} contains URLs).
*
* @throws IOException if there are any I/O errors.
*/
public static void writeImageMap(PrintWriter writer, String name,
ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator)
throws IOException {
writer.println(ImageMapUtils.getImageMap(name, info,
toolTipTagFragmentGenerator, urlTagFragmentGenerator));
}
示例14: getImageMap
import org.jfree.chart.imagemap.ToolTipTagFragmentGenerator; //导入依赖的package包/类
/**
* Creates an HTML image map. This method maps directly to
* {@link ImageMapUtils#getImageMap(String, ChartRenderingInfo,
* ToolTipTagFragmentGenerator, URLTagFragmentGenerator)}.
*
* @param name the map name ({@code null} not permitted).
* @param info the chart rendering info ({@code null} not permitted).
* @param toolTipTagFragmentGenerator a generator for the HTML fragment
* that will contain the tooltip text ({@code null} not permitted
* if {@code info} contains tooltip information).
* @param urlTagFragmentGenerator a generator for the HTML fragment that
* will contain the URL reference ({@code null} not permitted if
* {@code info} contains URLs).
*
* @return The map tag.
*/
public static String getImageMap(String name, ChartRenderingInfo info,
ToolTipTagFragmentGenerator toolTipTagFragmentGenerator,
URLTagFragmentGenerator urlTagFragmentGenerator) {
return ImageMapUtils.getImageMap(name, info,
toolTipTagFragmentGenerator, urlTagFragmentGenerator);
}