Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

oracle.jdeveloper.compare
Class CompareViewer

java.lang.Object
  extended by oracle.jdeveloper.compare.CompareViewer

public abstract class CompareViewer
extends java.lang.Object

Public API to the standalone compare viewer. JDeveloper extensions can use this API to integrate into compare functionality in the IDE.


Field Summary
static java.lang.String COMPARE_EACH_OTHER_COMMAND
          Use this constant to retrieve the cmdId of the Compare with > Each Other action.
static java.lang.String COMPARE_FILE_ON_DISK_COMMAND
          Use this constant to retrieve the cmdId of the Compare with > File on Disk action.
static java.lang.String COMPARE_OTHER_FILE_COMMAND
          Use this constant to retrieve the cmdId of the Compare with > Other File...
static float COMPARE_WITH_SECTION_MULTI
           
static float COMPARE_WITH_SECTION_SINGLE
           
static float COMPARE_WITH_WEIGHT_EACH_OTHER
           
static float COMPARE_WITH_WEIGHT_FILE_ON_DISK
           
static float COMPARE_WITH_WEIGHT_OTHER_FILE
           
 
Constructor Summary
CompareViewer()
           
 
Method Summary
static CompareViewer get()
          Convenience method that gets the compare viewer instance using JNDI.
 javax.swing.JMenu getBaseContextCompareMenu()
          Get the compare menu.
abstract  javax.swing.JMenu getContextCompareMenu()
          Get the compare context menu
abstract  javax.swing.JMenu getMainCompareMenu()
          Deprecated. compare menu defined in extension manifest
static boolean isContentComparable(java.net.URL url)
          Deprecated. replaced by CompareManager.isContentComparable(java.net.URL). Note that the new method returns true for certain comparable binary file types, as recognized by a registered CompareMethod.
 void show(CompareContributor left, CompareContributor right)
          Deprecated. replaced by #show(CompareContributor,CompareContributor,Node).
abstract  void show(CompareContributor left, CompareContributor right, Element contextNode)
          Display the compare viewer for the specified two contributors.
 void show(java.net.URL left, java.net.URL right)
          Deprecated. replaced by #show(URL,URL,Node).
 void show(java.net.URL left, java.net.URL right, Element contextNode)
          Display the compare viewer for the specified two URLs.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

COMPARE_WITH_SECTION_MULTI

public static final float COMPARE_WITH_SECTION_MULTI
See Also:
Constant Field Values

COMPARE_WITH_SECTION_SINGLE

public static final float COMPARE_WITH_SECTION_SINGLE
See Also:
Constant Field Values

COMPARE_WITH_WEIGHT_EACH_OTHER

public static final float COMPARE_WITH_WEIGHT_EACH_OTHER
See Also:
Constant Field Values

COMPARE_WITH_WEIGHT_FILE_ON_DISK

public static final float COMPARE_WITH_WEIGHT_FILE_ON_DISK
See Also:
Constant Field Values

COMPARE_WITH_WEIGHT_OTHER_FILE

public static final float COMPARE_WITH_WEIGHT_OTHER_FILE
See Also:
Constant Field Values

COMPARE_FILE_ON_DISK_COMMAND

public static final java.lang.String COMPARE_FILE_ON_DISK_COMMAND
Use this constant to retrieve the cmdId of the Compare with > File on Disk action. e.g.:
   Integer cmdId = Ide.findCmdID( CompareViewer.COMPARE_FILE_ON_DISK_COMMAND );
   if ( cmdId != null ) {
     IdeAction action = IdeAction.find( cmdId.intValue() );
   }
 
This can be used to override the default behavior of this action, e.g. by hooking in a chained controller.

See Also:
Constant Field Values

COMPARE_OTHER_FILE_COMMAND

public static final java.lang.String COMPARE_OTHER_FILE_COMMAND
Use this constant to retrieve the cmdId of the Compare with > Other File... action. e.g.:
   Integer cmdId = Ide.findCmdID( CompareViewer.COMPARE_OTHER_FILE_COMMAND );
   if ( cmdId != null ) {
     IdeAction action = IdeAction.find( cmdId.intValue() );
   }
 
This can be used to override the default behavior of this action, e.g. by hooking in a chained controller.

See Also:
Constant Field Values

COMPARE_EACH_OTHER_COMMAND

public static final java.lang.String COMPARE_EACH_OTHER_COMMAND
Use this constant to retrieve the cmdId of the Compare with > Each Other action. e.g.:
   Integer cmdId = Ide.findCmdID( CompareViewer.COMPARE_EACH_OTHER_COMMAND );
   if ( cmdId != null ) {
     IdeAction action = IdeAction.find( cmdId.intValue() );
   }
 
This can be used to override the default behavior of this action, e.g. by hooking in a chained controller.

See Also:
Constant Field Values
Constructor Detail

CompareViewer

public CompareViewer()
Method Detail

get

public static final CompareViewer get()
Convenience method that gets the compare viewer instance using JNDI. This method may return null.


isContentComparable

@Deprecated
public static final boolean isContentComparable(java.net.URL url)
Deprecated. replaced by CompareManager.isContentComparable(java.net.URL). Note that the new method returns true for certain comparable binary file types, as recognized by a registered CompareMethod.

Asks whether the content of the given URL is comparable.

Parameters:
url - the url.
Returns:
true if the URL represents comparable content.

getMainCompareMenu

@Deprecated
public abstract javax.swing.JMenu getMainCompareMenu()
Deprecated. compare menu defined in extension manifest

Get the compare menu.

Returns:
the compare menu.

getContextCompareMenu

public abstract javax.swing.JMenu getContextCompareMenu()
Get the compare context menu

Returns:
the compare context menu.

getBaseContextCompareMenu

public javax.swing.JMenu getBaseContextCompareMenu()
Get the compare menu. This menu has no version specific extension menu items

Returns:
the compare menu.

show

@Deprecated
public final void show(CompareContributor left,
                                  CompareContributor right)
Deprecated. replaced by #show(CompareContributor,CompareContributor,Node).

Display the compare viewer for the specified two contributors.

Parameters:
left - the contributor to display on the left of the compare viewer
right - the contributor to display on the right of the compare viewer

show

public abstract void show(CompareContributor left,
                          CompareContributor right,
                          Element contextNode)
Display the compare viewer for the specified two contributors.

Parameters:
left - the contributor to display on the left of the compare viewer
right - the contributor to display on the right of the compare viewer
contextNode - the real node from the context, used when an artificial node (and URL) is associated with the view.

show

@Deprecated
public final void show(java.net.URL left,
                                  java.net.URL right)
Deprecated. replaced by #show(URL,URL,Node).

Display the compare viewer for the specified two URLs.

Parameters:
left - the url of the file to display on the left of the compare viewer
right - the url of the file to display on the right of the compare viewer

show

public final void show(java.net.URL left,
                       java.net.URL right,
                       Element contextNode)
Display the compare viewer for the specified two URLs.

Parameters:
left - the url of the file to display on the left of the compare viewer
right - the url of the file to display on the right of the compare viewer

Oracle Fusion Middleware Java API Reference for Oracle Extension SDK
11g Release 2 (11.1.2.0.0)

E17493-01

Copyright © 1997, 2011, Oracle. All rights reserved.