public class

CodeCoordinatesUtil

extends Object
java.lang.Object
   ↳ com.pnfsoftware.jeb.core.output.code.coordinates.CodeCoordinatesUtil

Class Overview

Utility methods for ICodeCoordinates implementing classes.

Summary

Public Constructors
CodeCoordinatesUtil()
Public Methods
static int distance(ICodeCoordinates a, ICodeCoordinates b)
Calculate the distance between two coordinates.
static Integer getBaseObjectIndex(ICodeCoordinates coords)
Provide the base object index of a coordinates object.
static Integer getMethodObjectIndex(ICodeCoordinates coords)
Provide the method object index of a coordinates object.
static ICodeCoordinates getMostAccurate(ICodeCoordinates a, ICodeCoordinates b)
Determine which coordinates appear to be the most "accurate".
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public CodeCoordinatesUtil ()

Public Methods

public static int distance (ICodeCoordinates a, ICodeCoordinates b)

Calculate the distance between two coordinates.

Parameters
a first coordinates
b second coordinates
Returns
  • a positive number

public static Integer getBaseObjectIndex (ICodeCoordinates coords)

Provide the base object index of a coordinates object.

Returns
  • an index, null if the coordinates object does not use a base object (eg, NativeCoordinates)

public static Integer getMethodObjectIndex (ICodeCoordinates coords)

Provide the method object index of a coordinates object.

Returns
  • an index, null if the coordinates object does not use a method object

public static ICodeCoordinates getMostAccurate (ICodeCoordinates a, ICodeCoordinates b)

Determine which coordinates appear to be the most "accurate".

Parameters
a first coordinates
b second coordinates
Returns
  • whichever coordinates appear to be the most accurate; if no determination can Be found, the first coordinates are preferred.