public void handleEvent(Event evt) {
if (!(evt instanceof AbstractEvent)) return;
final AbstractEvent ae = (AbstractEvent)evt;
List l = ae.getDefaultActions();
if (l != null) {
Iterator i = l.iterator();
while (i.hasNext()) {
Object o = i.next();
if (o instanceof AnchorDefaultActionable)
return; // only one anchor in default list...
}
}
SVGAElement elt = (SVGAElement)evt.getCurrentTarget();
ae.addDefaultAction(new AnchorDefaultActionable
(elt,userAgent,holder));
}
项目:Push2display
文件:SVGAElementBridge.java
public void handleEvent(Event evt) {
if (!(evt instanceof AbstractEvent)) return;
final AbstractEvent ae = (AbstractEvent)evt;
List l = ae.getDefaultActions();
if (l != null) {
Iterator i = l.iterator();
while (i.hasNext()) {
Object o = i.next();
if (o instanceof MouSEOverDefaultActionable)
return; // only one anchor in default list...
}
}
Element target = (Element)ae.getTarget();
SVGAElement elt = (SVGAElement)ae.getCurrentTarget();
ae.addDefaultAction(new MouSEOverDefaultActionable
(target,elt,holder));
}
项目:Push2display
文件:SVGAElementBridge.java
public void handleEvent(Event evt) {
if (!(evt instanceof AbstractEvent)) return;
final AbstractEvent ae = (AbstractEvent)evt;
List l = ae.getDefaultActions();
if (l != null) {
Iterator i = l.iterator();
while (i.hasNext()) {
Object o = i.next();
if (o instanceof MouSEOutDefaultActionable)
return; // only one anchor in default list...
}
}
SVGAElement elt = (SVGAElement)evt.getCurrentTarget();
ae.addDefaultAction(new MouSEOutDefaultActionable
(elt,holder));
}
项目:feathers-sdk
文件:SVGAElementBridge.java
public void handleEvent(Event evt) {
if (!(evt instanceof AbstractEvent)) return;
final AbstractEvent ae = (AbstractEvent)evt;
List l = ae.getDefaultActions();
if (l != null) {
Iterator i = l.iterator();
while (i.hasNext()) {
Object o = i.next();
if (o instanceof AnchorDefaultActionable)
return; // only one anchor in default list...
}
}
SVGAElement elt = (SVGAElement)evt.getCurrentTarget();
ae.addDefaultAction(new AnchorDefaultActionable
(elt,holder));
}
项目:feathers-sdk
文件:SVGAElementBridge.java
public void handleEvent(Event evt) {
if (!(evt instanceof AbstractEvent)) return;
final AbstractEvent ae = (AbstractEvent)evt;
List l = ae.getDefaultActions();
if (l != null) {
Iterator i = l.iterator();
while (i.hasNext()) {
Object o = i.next();
if (o instanceof MouSEOverDefaultActionable)
return; // only one anchor in default list...
}
}
Element target = (Element)ae.getTarget();
SVGAElement elt = (SVGAElement)ae.getCurrentTarget();
ae.addDefaultAction(new MouSEOverDefaultActionable
(target,holder));
}
项目:feathers-sdk
文件:SVGAElementBridge.java
public void handleEvent(Event evt) {
if (!(evt instanceof AbstractEvent)) return;
final AbstractEvent ae = (AbstractEvent)evt;
List l = ae.getDefaultActions();
if (l != null) {
Iterator i = l.iterator();
while (i.hasNext()) {
Object o = i.next();
if (o instanceof MouSEOutDefaultActionable)
return; // only one anchor in default list...
}
}
SVGAElement elt = (SVGAElement)evt.getCurrentTarget();
ae.addDefaultAction(new MouSEOutDefaultActionable
(elt,holder));
}
/**
* Unsupported operation.
*/
public final void openLink(SVGAElement elt)
{
}
项目:fop
文件:PDFAElementBridge.java
/**
* Builds using the specified BridgeContext and element,the
* specified graphics node.
*
* @param ctx the bridge context to use
* @param e the element that describes the graphics node to build
* @return node the new graphics node
*/
public GraphicsNode createGraphicsNode(BridgeContext ctx,Element e) {
PDFANode aNode = (PDFANode)super.createGraphicsNode(ctx,e);
aNode.setDestination(((SVGAElement)e).getHref().getBaseVal());
aNode.setTransform(transform);
return aNode;
}
项目:Push2display
文件:UserAgent.java
/**
* Opens a link.
* @param elt The activated link element.
*/
void openLink(SVGAElement elt);
/**
* Creates a new LinkActivationEvent.
* @param source the object that originated the event,ie. the
* GVTTreeBuilder.
* @param link the link element.
* @param uri the URI of the document loaded.
*/
public LinkActivationEvent(Object source,SVGAElement link,String uri) {
super(source);
referencedURI = uri;
}
项目:feathers-sdk
文件:UserAgent.java
/**
* Opens a link.
* @param elt The activated link element.
*/
void openLink(SVGAElement elt);
public SVGDocument getSVGDocument() {
String xmlParser = XMLResourceDescriptor.getXMLParserClassName();
SAXSVGDocumentFactory df = new SAXSVGDocumentFactory(xmlParser);
SVGDocument doc = null;
try {
if (this.href != null) {
if (!this.href.substring(0,4).equalsIgnoreCase("file")) {
URL res = ExternalGraphic.class.getResource(this.href);
if (res != null) {
doc = df.createSVGDocument(
ExternalGraphic.class.getResource(this.href).toString());
}
} else {
doc = df.createSVGDocument(this.href);
}
}
} catch (IOException e) {
e.printstacktrace();
}
return doc;
}
项目:Push2display
文件:DocumentLoader.java
/**
* Returns a document from the specified uri.
* @param uri the uri of the document
* @exception IOException if an I/O error occured while loading
* the document
*/
public Document loadDocument(String uri) throws IOException {
Document ret = checkCache(uri);
if (ret != null)
return ret;
SVGDocument document = documentFactory.createSVGDocument(uri);
DocumentDescriptor desc = documentFactory.getDocumentDescriptor();
DocumentState state = new DocumentState(uri,document,desc);
synchronized (cacheMap) {
cacheMap.put(uri,state);
}
return state.getDocument();
}
项目:Push2display
文件:DocumentLoader.java
/**
* Returns a document from the specified uri.
* @param uri the uri of the document
* @exception IOException if an I/O error occured while loading
* the document
*/
public Document loadDocument(String uri,InputStream is)
throws IOException {
Document ret = checkCache(uri);
if (ret != null)
return ret;
SVGDocument document = documentFactory.createSVGDocument(uri,is);
DocumentDescriptor desc = documentFactory.getDocumentDescriptor();
DocumentState state = new DocumentState(uri,state);
}
return state.getDocument();
}
项目:Push2display
文件:JSVGScrollPane.java
protected Rectangle2D getViewBoxRect() {
SVGDocument doc = canvas.getSVGDocument();
if (doc == null) return null;
SVGSVGElement el = doc.getRootElement();
if (el == null) return null;
String viewBoxStr = el.getAttributeNS
(null,SVGConstants.SVG_VIEW_Box_ATTRIBUTE);
if (viewBoxStr.length() != 0) {
float[] rect = ViewBox.parseViewBoxAttribute(el,viewBoxStr,null);
return new Rectangle2D.Float(rect[0],rect[1],rect[2],rect[3]);
}
GraphicsNode gn = canvas.getGraphicsNode();
if (gn == null) return null;
Rectangle2D bounds = gn.getBounds();
if (bounds == null) return null;
return (Rectangle2D) bounds.clone();
}
项目:Push2display
文件:JSVGComponent.java
/**
* This Implementation simply forwards the request to the AWT thread.
*
* @param e The <image> element that can't be loaded.
* @param url The resolved url that can't be loaded.
* @param msg As best as can be determined the reason it can't be
* loaded (not available,corrupt,unkNown format,...).
*/
public SVGDocument getbrokenLinkDocument(final Element e,final String url,final String msg) {
if (EventQueue.isdispatchThread())
return userAgent.getbrokenLinkDocument(e,url,msg);
class Query implements Runnable {
SVGDocument doc;
RuntimeException rex = null;
public void run() {
try {
doc = userAgent.getbrokenLinkDocument(e,msg);
} catch (RuntimeException re) { rex = re; }
}
}
Query q = new Query();
invokeAndWait(q);
if (q.rex != null) throw q.rex;
return q.doc;
}
项目:NBModeler
文件:SvgWidget.java
public void setSVGDocument(SVGDocument doc) {
svgDocument = doc;
UserAgent userAgent = new UserAgentAdapter();
DocumentLoader loader = new DocumentLoader(userAgent);
ctx = new BridgeContext(userAgent,loader);
ctx.setDynamicState(BridgeContext.DYNAMIC);
GVTBuilder builder = new GVTBuilder();
setGraphicsNode(builder.build(ctx,getSvgDocument()));
outlineElement = doc.getElementById("OUTLINE");
if (outlineElement != null) {
outlineshape = ((org.apache.batik.gvt.ShapeNode) ctx.getGraphicsNode(outlineElement)).getShape();
}
if ("OUTER".equals(doc.getRootElement().getAttribute("resizeType"))) {
setResizeType(ResizeType.OUTER);
}
revalidate();
}
项目:compomics-utilities
文件:Export.java
/**
* Draws the selected component (assumed to be a Component) into the
* provided SVGGraphics2D object.
*
* @param component
* @param bounds
*/
private static SVGGraphics2D drawSvgGraphics(Object component,Rectangle bounds) {
// Get a SVGDOMImplementation and create an XML document
DOMImplementation domImpl = SVGDOMImplementation.getDOMImplementation();
String svgNS = "http://www.w3.org/2000/svg";
SVGDocument svgDocument = (SVGDocument) domImpl.createDocument(svgNS,"svg",null);
// Create an instance of the SVG Generator
SVGGraphics2D svgGenerator = new SVGGraphics2D(svgDocument);
svgGenerator.setSVGCanvasSize(bounds.getSize());
// draw the panel in the SVG generator
if (component instanceof JFreeChart) {
((JFreeChart) component).draw(svgGenerator,bounds);
} else if (component instanceof JComponent) {
((JComponent) component).paintAll(svgGenerator);
}
return svgGenerator;
}
项目:elki
文件:SVGUtil.java
/**
* Convert the coordinates of an DOM Event from screen into element
* coordinates.
*
* @param doc Document context
* @param tag Element containing the coordinate system
* @param evt Event to interpret
* @return coordinates
*/
public static SVGPoint elementCoordinatesFromEvent(Document doc,Element tag,Event evt) {
try {
DOMMouseEvent gnme = (DOMMouseEvent) evt;
SVGMatrix mat = ((SVGLocatable) tag).getScreenCTM();
SVGMatrix imat = mat.inverse();
SVGPoint cPt = ((SVGDocument) doc).getRootElement().createSVGPoint();
cPt.setX(gnme.getClientX());
cPt.setY(gnme.getClientY());
return cPt.matrixTransform(imat);
}
catch(Exception e) {
LoggingUtil.warning("Error getting coordinates from SVG event.",e);
return null;
}
}
项目:mitraq
文件:Export.java
/**
* Draws the selected component (assumed to be a Component) into the provided
* SVGGraphics2D object.
*
* @param component
* @param bounds
*/
private static SVGGraphics2D drawSvgGraphics(Object component,bounds);
} else if (component instanceof JComponent) {
((JComponent) component).paintAll(svgGenerator);
}
return svgGenerator;
}
项目:feathers-sdk
文件:DocumentLoader.java
/**
* Returns a document from the specified uri.
* @param uri the uri of the document
* @exception IOException if an I/O error occured while loading
* the document
*/
public Document loadDocument(String uri,InputStream is)
throws IOException {
Document ret = checkCache(uri);
if (ret != null)
return ret;
SVGDocument document = documentFactory.createSVGDocument(uri,state);
}
return state.getDocument();
}
项目:tabularius
文件:DocumentForm.java
public void execdisplayField(Field field,SVGDocument svgDocument) {
clearErrorStatus();
try {
FieldForm form = new FieldForm(field,svgDocument);
DocumentForm.this.getFieldByClass(GroupFormField.class).setInnerForm(form);
} catch (Exception e) {
e.printstacktrace();
addErrorStatus(e.getMessage());
}
}
项目:tabularius
文件:DocumentForm.java
protected SVGDocument transformleft(SVGDocument input,Field field) throws IOException {
SVGDocument doc = (SVGDocument) input.cloneNode(true);
AtomicInteger counter = new AtomicInteger(0);
document.fields.forEach(f -> {
int number = counter.getAndIncrement();
int height = 100;
int space = 33;
int base = 600 + number * (height + space);
Element fieldMarker = doc.createElementNS("http://www.w3.org/2000/svg","polygon");
fieldMarker.setAttribute("points","-10000," + base + " -10000," + (base + height) + " 10000,"
+ (base + height) + " 10000," + base);
fieldMarker.setAttribute("id","fieldMarker" + number);
fieldMarker.setAttribute("data-ref","fieldMarker" + number);
fieldMarker.setAttribute("class","app-link");
fieldMarker.setAttribute("fill","#014786");
fieldMarker.setAttribute("fill-opacity","0.0");
Element set = doc.createElementNS("http://www.w3.org/2000/svg","set");
set.setAttribute("attributeName","fill-opacity");
set.setAttribute("to","0.1");
set.setAttribute("begin","fieldMarker" + number + ".mouSEOver");
set.setAttribute("end","fieldMarker" + number + ".mouSEOut");
fieldMarker.appendChild(set);
Element documentElement = doc.getElementById("document");
documentElement.getParentNode().appendChild(fieldMarker);
});
return doc;
}
项目:tabularius
文件:DocumentForm.java
protected SVGDocument transformRight(SVGDocument input,Field field) throws IOException {
SVGDocument doc = (SVGDocument) input.cloneNode(true);
int height = 100;
int space = 33;
int base = 605 + document.fields.indexOf(field) * (height + space);
doc.getElementById("svg").setAttribute("viewBox","-10 " + base + " 861 " + (base + height));
doc.getElementById("svg").setAttribute("preserveAspectRatio","xMinYMin slice");
return doc;
}
public GraphicsNode getGraphicsNode() {
SVGDocument doc = this.getSVGDocument();
if (doc == null)
return null;
UserAgent userAgent = new UserAgentAdapter();
DocumentLoader loader = new DocumentLoader(userAgent);
BridgeContext ctx = new BridgeContext(userAgent,loader);
ctx.setDynamicState(BridgeContext.DYNAMIC);
GVTBuilder builder = new GVTBuilder();
GraphicsNode rootGN = builder.build(ctx,doc);
return rootGN;
}
项目:Push2display
文件:SVGImage.java
/**
* Load the SVG image from an input stream and replaces its color. The SVG format is a XML
* format.
*
* @param inputStream From which to load the image
* @param color The replacement color
* @return The loaded SVG image document
* @throws SAXException Parsing error
* @throws IOException Could not load the image
* @throws ParserConfigurationException Problem with XML parser
*/
public Document loadDocument (final InputStream inputStream,final Color color) throws SAXException,IOException,ParserConfigurationException
{
final String parser = XMLResourceDescriptor.getXMLParserClassName ();
final SAXSVGDocumentFactory f = new SAXSVGDocumentFactory (parser);
final SVGDocument document = f.createSVGDocument ("xxx",inputStream);
changeColorOfElement (color,"polygon");
changeColorOfElement (color,"circle");
changeColorOfElement (color,"path");
changeColorOfElement (color,"rect");
return document;
}
项目:Push2display
文件:SVGImage.java
/**
* Adds a new fill color to all given elements.
*
* @param color The replacement color
* @param document The document in which to replace the color
* @param elementName The name of an XML element for which to replace the color
*/
private static void changeColorOfElement (final Color color,final SVGDocument document,final String elementName)
{
final NodeList nodes = document.getElementsByTagName (elementName);
for (int i = 0; i < nodes.getLength (); i++)
{
if (nodes.item (i) instanceof SVGElement)
{
final SVGElement element = (SVGElement) nodes.item (i);
element.setAttribute ("fill",toText (color));
}
}
}
项目:Push2display
文件:DocumentLoader.java
/**
* Returns the line in the source code of the specified element or
* -1 if not found.
*
* @param e the element
* @return -1 the document has been removed from the cache or has not
* been loaded by this document loader.
*/
public int getLineNumber(Element e) {
String uri = ((SVGDocument)e.getownerDocument()).getURL();
DocumentState state;
synchronized (cacheMap) {
state = (DocumentState)cacheMap.get(uri);
}
if (state == null) {
return -1;
} else {
return state.desc.getLocationLine(e);
}
}
项目:Push2display
文件:ScriptingEnvironment.java
/**
* Runs the script.
*/
public void handleEvent(Event evt) {
Element elt = (Element)evt.getCurrentTarget();
// Evaluate the script
String script = elt.getAttributeNS(null,attribute);
if (script.length() == 0)
return;
DocumentLoader dl = bridgeContext.getDocumentLoader();
SVGDocument d = (SVGDocument)elt.getownerDocument();
int line = dl.getLineNumber(elt);
final String desc = Messages.formatMessage
(EVENT_SCRIPT_DESCRIPTION,new Object [] {d.getURL(),attribute,new Integer(line)});
// Find the scripting language
Element e = elt;
while (e != null &&
(!SVGConstants.SVG_NAMESPACE_URI.equals
(e.getNamespaceURI()) ||
!SVGConstants.SVG_SVG_TAG.equals(e.getLocalName()))) {
e = SVGUtilities.getParentElement(e);
}
if (e == null)
return;
String lang = e.getAttributeNS
(null,SVGConstants.SVG_CONTENT_SCRIPT_TYPE_ATTRIBUTE);
runEventHandler(script,evt,lang,desc);
}
项目:Push2display
文件:BaseScriptingEnvironment.java
/**
* Creates a new BaseScriptingEnvironment.
* @param ctx the bridge context
*/
public BaseScriptingEnvironment(BridgeContext ctx) {
bridgeContext = ctx;
document = ctx.getDocument();
docpuRL = new ParsedURL(((SVGDocument)document).getURL());
userAgent = bridgeContext.getUserAgent();
}
项目:Push2display
文件:BridgeContext.java
/**
* Tells whether the given SVG document is Interactive.
* We say it is,if it has any <title>,<desc>,or <a> elements,* of if the 'cursor' property is anything but Auto on any element.
*/
public boolean isInteractiveDocument(Document doc) {
Element root = ((SVGDocument)doc).getRootElement();
if (!SVGConstants.SVG_NAMESPACE_URI.equals(root.getNamespaceURI()))
return false;
return checkInteractiveElement(root);
}
项目:Push2display
文件:SVGImageElementBridge.java
/**
* Returns a GraphicsNode that represents an raster image in JPEG or PNG
* format.
*
* @param ctx the bridge context
* @param e the image element
* @param img the image to use in creating the graphics node
*/
protected GraphicsNode createrasterImageNode(BridgeContext ctx,Element e,Filter img,ParsedURL purl) {
Rectangle2D bounds = getimageBounds(ctx,e);
if ((bounds.getWidth() == 0) || (bounds.getHeight() == 0)) {
ShapeNode sn = new ShapeNode();
sn.setShape(bounds);
return sn;
}
if (brokenLinkProvider.hasbrokenLinkProperty(img)) {
Object o=img.getProperty(brokenLinkProvider.broKEN_LINK_PROPERTY);
String msg = "unkNown";
if (o instanceof String)
msg = (String)o;
SVGDocument doc = ctx.getUserAgent().getbrokenLinkDocument
(e,purl.toString(),msg);
return createSVGImageNode(ctx,e,doc);
}
RasterImageNode node = new RasterImageNode();
node.setimage(img);
Rectangle2D imgBounds = img.getBounds2D();
// create the implicit viewBox for the raster image. The viewBox for a
// raster image is the size of the image
float [] vb = new float[4];
vb[0] = 0; // x
vb[1] = 0; // y
vb[2] = (float)imgBounds.getWidth(); // width
vb[3] = (float)imgBounds.getHeight(); // height
// handles the 'preserveAspectRatio','overflow' and 'clip' and sets the
// appropriate AffineTransform to the image node
initializeViewport(ctx,node,vb,bounds);
return node;
}
/**
* Creates a new SVGLoadEventdispatcher.
*/
public SVGLoadEventdispatcher(GraphicsNode gn,SVGDocument doc,BridgeContext bc,UpdateManager um) {
svgDocument = doc;
root = gn;
bridgeContext = bc;
updateManager = um;
}
项目:Push2display
文件:JSVGCanvas.java
/**
* Sets the tool tip on the input element.
*/
public void setToolTip(Element elt,String toolTip){
if (toolTipMap == null) {
toolTipMap = new WeakHashMap();
}
if (toolTipDocs == null) {
toolTipDocs = new WeakHashMap();
}
SVGDocument doc = (SVGDocument)elt.getownerDocument();
if (toolTipDocs.put(doc,MAP_TOKEN) == null) {
NodeEventTarget root;
root = (NodeEventTarget)doc.getRootElement();
// On mouSEOver,it sets the tooltip to the given value
root.addEventListenerNS(XMLConstants.XML_EVENTS_NAMESPACE_URI,SVGConstants.SVG_EVENT_MOUSEOVER,toolTipListener,false,null);
// On mouSEOut,it removes the tooltip
root.addEventListenerNS(XMLConstants.XML_EVENTS_NAMESPACE_URI,SVGConstants.SVG_EVENT_MOUSEOUT,null);
}
toolTipMap.put(elt,toolTip);
if (elt == lastTarget)
EventQueue.invokelater(new ToolTipRunnable(toolTip));
}
项目:Push2display
文件:NullSetSVGDocumentTest.java
public JSVGCanvasHandler createHandler() {
return new JSVGCanvasHandler(this,this) {
public JSVGCanvas createCanvas() {
return new JSVGCanvas() {
protected void installSVGDocument(SVGDocument doc){
super.installSVGDocument(doc);
if (doc != null) return;
handler.scriptDone();
}
};
}
};
}
/**
* This method is called by the SVG viewer
* when the scripts are loaded to register
* the listener needed.
* @param doc The current document.
*/
public void initializeEventListeners(SVGDocument doc) {
System.err.println(">>>>>>>>>>>>>>>>>>> SVGDocument : " + doc);
((EventTarget)doc.getElementById("testContent")).
addEventListener("mousedown",new EventListener() {
public void handleEvent(Event evt) {
((Element)evt.getTarget()).setAttributeNS(null,"fill","orange");
}
},false);
}
项目:mars-sim
文件:SVGLoader.java
/**
* Load the SVG image with the specified name. This operation may either
* create a new graphics node of returned a prevIoUsly created one.
* @param name Name of the SVG file to load.
* @return GraphicsNode containing SVG image or null if none found.
*/
public static GraphicsNode getSVGImage(String name) {
if (svgCache == null) svgCache = new HashMap<String,GraphicsNode>();
GraphicsNode found = svgCache.get(name);
if (found == null) {
String fileName = SVG_DIR + name;
URL resource = SVGLoader.class.getResource(fileName);
try {
String xmlParser = XMLResourceDescriptor.getXMLParserClassName();
SAXSVGDocumentFactory df = new SAXSVGDocumentFactory(xmlParser);
SVGDocument doc = df.createSVGDocument(resource.toString());
UserAgent userAgent = new UserAgentAdapter();
DocumentLoader loader = new DocumentLoader(userAgent);
BridgeContext ctx = new BridgeContext(userAgent,loader);
ctx.setDynamicState(BridgeContext.DYNAMIC);
GVTBuilder builder = new GVTBuilder();
found = builder.build(ctx,doc);
svgCache.put(name,found);
}
catch (Exception e) {
System.err.println("getSVGImage error: " + fileName);
e.printstacktrace(System.err);
}
}
return found;
}
项目:eurocarbdb
文件:SvgFactory.java
/**
* Create the SVGDocument and the SVGGraphics2D objects of this SvgFactory.
* This method is called by the constructors.
*/
private void setupFactory() {
DOMImplementation impl = SVGDOMImplementation.getDOMImplementation();
String svgNS = SVGDOMImplementation.SVG_NAMESPACE_URI;
this.setSvgDoc((SVGDocument) impl.createDocument(svgNS,null));
SVGGeneratorContext ctx = SVGGeneratorContext.createDefault(this.getSvgDoc());
ctx.setComment("Generated by MonosaccharideDB (www.monosaccharidedb.org) with Batik SVG Generator");
this.setSVGGraph2D(new SVGGraphics2D(ctx,false));
}
项目:eurocarbdb
文件:SvgFactory.java
public void display() {
SVGDocument doc = this.getSvgDoc();
JSVGCanvas canvas = new JSVGCanvas();
org.w3c.dom.Element root = doc.getDocumentElement();
this.getRoot(root);
JFrame f = new JFrame();
f.getContentPane().add(canvas);
canvas.setSVGDocument(doc);
f.pack();
f.setVisible(true);
//f.dispose();
}