code stringlengths 73 34.1k | label stringclasses 1
value |
|---|---|
@Pure
@SuppressWarnings("checkstyle:npathcomplexity")
public static File convertURLToFile(URL url) {
URL theUrl = url;
if (theUrl == null) {
return null;
}
if (URISchemeType.RESOURCE.isURL(theUrl)) {
theUrl = Resources.getResource(decodeHTMLEntities(theUrl.getFile()));
if (theUrl == null) {
theUr... | java |
@Pure
@SuppressWarnings({"checkstyle:cyclomaticcomplexity", "checkstyle:npathcomplexity"})
public static URL getParentURL(URL url) throws MalformedURLException {
if (url == null) {
return url;
}
String path = url.getPath();
final String prefix;
final String parentStr;
switch (URISchemeType.getSchemeTy... | java |
@Pure
@SuppressWarnings("checkstyle:magicnumber")
private static String extractLocalPath(String filename) {
if (filename == null) {
return null;
}
final int max = Math.min(FILE_PREFIX.length, filename.length());
final int inner = max - 2;
if (inner <= 0) {
return filename;
}
boolean foundInner = f... | java |
@Pure
public static boolean isWindowsNativeFilename(String filename) {
final String fn = extractLocalPath(filename);
if (fn == null || fn.length() == 0) {
return false;
}
final Pattern pattern = Pattern.compile(WINDOW_NATIVE_FILENAME_PATTERN);
final Matcher matcher = pattern.matcher(fn);
return matcher.... | java |
@Pure
public static File normalizeWindowsNativeFilename(String filename) {
final String fn = extractLocalPath(filename);
if (fn != null && fn.length() > 0) {
final Pattern pattern = Pattern.compile(WINDOW_NATIVE_FILENAME_PATTERN);
final Matcher matcher = pattern.matcher(fn);
if (matcher.find()) {
retu... | java |
@Pure
public static URL makeCanonicalURL(URL url) {
if (url != null) {
final String[] pathComponents = url.getPath().split(Pattern.quote(URL_PATH_SEPARATOR));
final List<String> canonicalPath = new LinkedList<>();
for (final String component : pathComponents) {
if (!CURRENT_DIRECTORY.equals(component))... | java |
public static void zipFile(File input, File output) throws IOException {
try (FileOutputStream fos = new FileOutputStream(output)) {
zipFile(input, fos);
}
} | java |
@SuppressWarnings("checkstyle:npathcomplexity")
public static void zipFile(File input, OutputStream output) throws IOException {
try (ZipOutputStream zos = new ZipOutputStream(output)) {
if (input == null) {
return;
}
final LinkedList<File> candidates = new LinkedList<>();
candidates.add(input);
... | java |
public static void unzipFile(InputStream input, File output) throws IOException {
if (output == null) {
return;
}
output.mkdirs();
if (!output.isDirectory()) {
throw new IOException(Locale.getString("E3", output)); //$NON-NLS-1$
}
try (ZipInputStream zis = new ZipInputStream(input)) {
final byte[]... | java |
public static void unzipFile(File input, File output) throws IOException {
try (FileInputStream fis = new FileInputStream(input)) {
unzipFile(fis, output);
}
} | java |
@Nonnull
public static KeyValueSink<Symbol, byte[]> forPalDB(final File dbFile,
final boolean compressValues)
throws IOException {
return PalDBKeyValueSink.forFile(dbFile, compressValues);
} | java |
public static <T> Set<T> sampleHashingSetWithoutReplacement(final Set<T> sourceSet,
final int numSamples,
final Random rng) {
checkArgument(numSamples <= sourceSet.size());
// first we find the indices of the selected elements
final List<Integer> selectedItems =
distinctRandomIntsInRang... | java |
@Pure
public List<S> getPath() {
if (this.path == null) {
return Collections.emptyList();
}
return Collections.unmodifiableList(this.path);
} | java |
public void setPath(List<? extends S> path, Direction1D direction) {
this.path = path == null || path.isEmpty() ? null : new ArrayList<>(path);
this.firstSegmentDirection = detectFirstSegmentDirection(direction);
} | java |
public void setIdentity() {
this.path = null;
this.firstSegmentDirection = detectFirstSegmentDirection(null);
this.curvilineTranslation = 0.;
this.shiftTranslation = 0.;
this.isIdentity = Boolean.TRUE;
} | java |
@Pure
public boolean isIdentity() {
if (this.isIdentity == null) {
this.isIdentity = MathUtil.isEpsilonZero(this.curvilineTranslation)
&& MathUtil.isEpsilonZero(this.curvilineTranslation);
}
return this.isIdentity.booleanValue();
} | java |
public void setTranslation(Tuple2D<?> position) {
assert position != null : AssertMessages.notNullParameter();
this.curvilineTranslation = position.getX();
this.shiftTranslation = position.getY();
this.isIdentity = null;
} | java |
public void translate(Tuple2D<?> move) {
assert move != null : AssertMessages.notNullParameter();
this.curvilineTranslation += move.getX();
this.shiftTranslation += move.getY();
this.isIdentity = null;
} | java |
void add(Iterable<SGraphSegment> segments) {
for (final SGraphSegment segment : segments) {
this.segments.add(segment);
}
} | java |
public static List<ConfigMetadataNode> extractConfigs(ModulesMetadata modulesMetadata) {
final List<ModuleMetadata> modules = modulesMetadata
.getModules()
.stream()
.collect(Collectors.toList());
return modules.stream()
.map(ModuleMetadata::getConfigs... | java |
@SuppressWarnings("checkstyle:npathcomplexity")
public static void defineConfig(Map<String, Object> content, ConfigMetadataNode config, Injector injector) {
assert content != null;
assert config != null;
final Class<?> type = (Class<?>) config.getType();
final String sectionName = config.getName();
final Pat... | java |
public static void defineScalar(Map<String, Object> content, String bootiqueVariable, Object value) throws Exception {
final String[] elements = bootiqueVariable.split("\\."); //$NON-NLS-1$
final Map<String, Object> entry = getScalarParent(content, elements);
entry.put(elements[elements.length - 1], value);
} | java |
public static Permutation createForNElements(final int numElements, final Random rng) {
final int[] permutation = IntUtils.arange(numElements);
IntUtils.shuffle(permutation, checkNotNull(rng));
return new Permutation(permutation);
} | java |
public void permute(final int[] arr) {
checkArgument(arr.length == sources.length);
final int[] tmp = new int[arr.length];
for (int i = 0; i < tmp.length; ++i) {
tmp[i] = arr[sources[i]];
}
System.arraycopy(tmp, 0, arr, 0, arr.length);
} | java |
private boolean setChild1(N newChild) {
if (this.child1 == newChild) {
return false;
}
if (this.child1 != null) {
this.child1.setParentNodeReference(null, true);
--this.notNullChildCount;
firePropertyChildRemoved(0, this.child1);
}
if (newChild != null) {
final N oldParent = newChild.getParen... | java |
private boolean setChild2(N newChild) {
if (this.child2 == newChild) {
return false;
}
if (this.child2 != null) {
this.child2.setParentNodeReference(null, true);
--this.notNullChildCount;
firePropertyChildRemoved(1, this.child2);
}
if (newChild != null) {
final N oldParent = newChild.getParen... | java |
private boolean setChild3(N newChild) {
if (this.child3 == newChild) {
return false;
}
if (this.child3 != null) {
this.child3.setParentNodeReference(null, true);
--this.notNullChildCount;
firePropertyChildRemoved(2, this.child3);
}
if (newChild != null) {
final N oldParent = newChild.getParen... | java |
private boolean setChild4(N newChild) {
if (this.child4 == newChild) {
return false;
}
if (this.child4 != null) {
this.child4.setParentNodeReference(null, true);
--this.notNullChildCount;
firePropertyChildRemoved(3, this.child4);
}
if (newChild != null) {
final N oldParent = newChild.getParen... | java |
public static Vector2i convert(Tuple2D<?> tuple) {
if (tuple instanceof Vector2i) {
return (Vector2i) tuple;
}
return new Vector2i(tuple.getX(), tuple.getY());
} | java |
String constructLogMsg() {
final StringBuilder msg = new StringBuilder();
for (final Map.Entry<String, List<StackTraceElement>> e : paramToStackTrace.build().entries()) {
msg.append("Parameter ").append(e.getKey()).append(" accessed at \n");
msg.append(FluentIterable.from(e.getValue())
//... | java |
public static GraphicsDevice[] getAvailableScreens()
{
final GraphicsEnvironment graphicsEnvironment = GraphicsEnvironment
.getLocalGraphicsEnvironment();
final GraphicsDevice[] graphicsDevices = graphicsEnvironment.getScreenDevices();
return graphicsDevices;
} | java |
public static boolean isScreenAvailableToShow(final int screen)
{
final GraphicsDevice[] graphicsDevices = getAvailableScreens();
boolean screenAvailableToShow = false;
if ((screen > -1 && screen < graphicsDevices.length) || (graphicsDevices.length > 0))
{
screenAvailableToShow = true;
}
return screenAv... | java |
@Nonnull
// it's reflection, can't avoid unchecked cast
@SuppressWarnings("unchecked")
public static Module classNameToModule(final Parameters parameters, final Class<?> clazz,
Optional<? extends Class<? extends Annotation>> annotation)
throws IllegalAccessException, InvocationTargetException, Instant... | java |
private static Optional<Module> instantiateWithPrivateConstructor(Class<?> clazz,
Class<?>[] parameters,
Object... paramVals)
throws InvocationTargetException, IllegalAccessException, InstantiationException {
final Constructor<?> constructor;
try {
constructor = clazz.getDeclaredConstruc... | java |
public static <K, V> PairedMapValues<V> zipValues(final Map<K, V> left, final Map<K, V> right) {
checkNotNull(left);
checkNotNull(right);
final ImmutableList.Builder<ZipPair<V, V>> pairedValues =
ImmutableList.builder();
final ImmutableList.Builder<V> leftOnly = ImmutableList.builder();
fina... | java |
public static <T> ImmutableMap<T, Integer> indexMap(Iterable<? extends T> items) {
final ImmutableMap.Builder<T, Integer> ret = ImmutableMap.builder();
int idx = 0;
for (final T item : items) {
ret.put(item, idx++);
}
return ret.build();
} | java |
public static <V> int longestKeyLength(Map<String, V> map) {
if (map.isEmpty()) {
return 0;
}
return Ordering.natural().max(
FluentIterable.from(map.keySet())
.transform(StringUtils.lengthFunction()));
} | java |
@Pure
public static double getPreferredRadius() {
final Preferences prefs = Preferences.userNodeForPackage(MapElementConstants.class);
if (prefs != null) {
return prefs.getDouble("RADIUS", DEFAULT_RADIUS); //$NON-NLS-1$
}
return DEFAULT_RADIUS;
} | java |
public static void setPreferredRadius(double radius) {
assert !Double.isNaN(radius);
final Preferences prefs = Preferences.userNodeForPackage(MapElementConstants.class);
if (prefs != null) {
prefs.putDouble("RADIUS", radius); //$NON-NLS-1$
try {
prefs.flush();
} catch (BackingStoreException exception... | java |
@Pure
public static int getPreferredColor() {
final Preferences prefs = Preferences.userNodeForPackage(MapElementConstants.class);
if (prefs != null) {
return prefs.getInt("COLOR", DEFAULT_COLOR); //$NON-NLS-1$
}
return DEFAULT_COLOR;
} | java |
public static void setPreferredColor(int color) {
final Preferences prefs = Preferences.userNodeForPackage(MapElementConstants.class);
if (prefs != null) {
prefs.putInt("COLOR", color); //$NON-NLS-1$
try {
prefs.flush();
} catch (BackingStoreException exception) {
//
}
}
} | java |
public static PhysicsEngine setPhysicsEngine(PhysicsEngine newEngine) {
final PhysicsEngine oldEngine = engine;
if (newEngine == null) {
engine = new JavaPhysicsEngine();
} else {
engine = newEngine;
}
return oldEngine;
} | java |
@Pure
@Inline(value = "PhysicsUtil.getPhysicsEngine().speed(($1), ($2))",
imported = {PhysicsUtil.class})
public static double speed(double movement, double dt) {
return engine.speed(movement, dt);
} | java |
@Pure
@Inline(value = "PhysicsUtil.getPhysicsEngine().acceleration(($1), ($2), ($3))",
imported = {PhysicsUtil.class})
public static double acceleration(
double previousSpeed,
double currentSpeed,
double dt) {
return engine.acceleration(previousSpeed, currentSpeed, dt);
} | java |
public static List<Point> computeDialogPositions(final int dialogWidth, final int dialogHeight)
{
List<Point> dialogPosition = null;
final int windowBesides = ScreenSizeExtensions.getScreenWidth() / dialogWidth;
final int windowBelow = ScreenSizeExtensions.getScreenHeight() / dialogHeight;
final int listSize =... | java |
public static GraphicsDevice[] getScreenDevices()
{
final GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
final GraphicsDevice[] gs = ge.getScreenDevices();
return gs;
} | java |
public static Dimension getScreenDimension(Component component)
{
int screenID = getScreenID(component);
Dimension dimension = new Dimension(0, 0);
GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
GraphicsConfiguration defaultConfiguration = ge.getScreenDevices()[screenID]
.getDe... | java |
public static int getScreenID(Component component)
{
int screenID;
final AtomicInteger counter = new AtomicInteger(-1);
Stream.of(getScreenDevices()).forEach(graphicsDevice -> {
GraphicsConfiguration gc = graphicsDevice.getDefaultConfiguration();
Rectangle rectangle = gc.getBounds();
if (rectangle.cont... | java |
@Pure
public Rectangle2d getCellBounds(int row, int column) {
final double cellWidth = getCellWidth();
final double cellHeight = getCellHeight();
final double x = this.bounds.getMinX() + cellWidth * column;
final double y = this.bounds.getMinY() + cellHeight * row;
return new Rectangle2d(x, y, cellWidth, cel... | java |
public GridCell<P> createCellAt(int row, int column) {
GridCell<P> cell = this.cells[row][column];
if (cell == null) {
cell = new GridCell<>(row, column, getCellBounds(row, column));
this.cells[row][column] = cell;
++this.cellCount;
}
return cell;
} | java |
public GridCell<P> removeCellAt(int row, int column) {
final GridCell<P> cell = this.cells[row][column];
if (cell != null) {
this.cells[row][column] = null;
--this.cellCount;
for (final P element : cell) {
removeElement(element);
}
}
return cell;
} | java |
public boolean addElement(P element) {
boolean changed = false;
if (element != null) {
final GridCellElement<P> gridElement = new GridCellElement<>(element);
for (final GridCell<P> cell : getGridCellsOn(element.getGeoLocation().toBounds2D(), true)) {
if (cell.addElement(gridElement)) {
changed = true... | java |
public boolean removeElement(P element) {
boolean changed = false;
if (element != null) {
GridCellElement<P> gridElement;
for (final GridCell<P> cell : getGridCellsOn(element.getGeoLocation().toBounds2D())) {
gridElement = cell.removeElement(element);
if (gridElement != null) {
if (cell.isEmpty()... | java |
@Pure
public int getColumnFor(double x) {
final double xx = x - this.bounds.getMinX();
if (xx >= 0.) {
final int idx = (int) (xx / getCellWidth());
assert idx >= 0;
if (idx < getColumnCount()) {
return idx;
}
return getColumnCount() - 1;
}
return 0;
} | java |
@Pure
public int getRowFor(double y) {
final double yy = y - this.bounds.getMinY();
if (yy >= 0.) {
final int idx = (int) (yy / getCellHeight());
assert idx >= 0;
if (idx < getRowCount()) {
return idx;
}
return getRowCount() - 1;
}
return 0;
} | java |
@Pure
public AroundCellIterable<P> getGridCellsAround(Point2D<?, ?> position, double maximalDistance) {
final int column = getColumnFor(position.getX());
final int row = getRowFor(position.getY());
return new AroundIterable(row, column, position, maximalDistance);
} | java |
@Pure
public Iterator<P> iterator(Rectangle2afp<?, ?, ?, ?, ?, ?> bounds) {
if (this.bounds.intersects(bounds)) {
final int c1 = getColumnFor(bounds.getMinX());
final int r1 = getRowFor(bounds.getMinY());
final int c2 = getColumnFor(bounds.getMaxX());
final int r2 = getRowFor(bounds.getMaxY());
return... | java |
@Pure
public P getElementAt(int index) {
if (index >= 0) {
int idx = 0;
int eIdx;
for (final GridCell<P> cell : getGridCells()) {
eIdx = idx + cell.getReferenceElementCount();
if (index < eIdx) {
try {
return cell.getElementAt(index - idx);
} catch (IndexOutOfBoundsException exceptio... | java |
protected final Object blockingWrite(SelectableChannel channel,
WriteMessage message, IoBuffer writeBuffer) throws IOException,
ClosedChannelException {
SelectionKey tmpKey = null;
Selector writeSelector = null;
int attempts = 0;
int bytesProduced = 0;
try {
while (writeBuffer.hasRemaining())... | java |
private int setSecDataArr(HashMap m, ArrayList arr, boolean isEvent) {
int idx = setSecDataArr(m, arr);
if (idx != 0 && isEvent && getValueOr(m, "date", "").equals("")) {
return -1;
} else {
return idx;
}
} | java |
private boolean isPlotInfoExist(Map expData) {
String[] plotIds = {"plta", "pltr#", "pltln", "pldr", "pltsp", "pllay", "pltha", "plth#", "plthl", "plthm"};
for (String plotId : plotIds) {
if (!getValueOr(expData, plotId, "").equals("")) {
return true;
}
}... | java |
private boolean isSoilAnalysisExist(ArrayList<HashMap> icSubArr) {
for (HashMap icSubData : icSubArr) {
if (!getValueOr(icSubData, "slsc", "").equals("")) {
return true;
}
}
return false;
} | java |
private ArrayList<HashMap> getDataList(Map expData, String blockName, String dataListName) {
HashMap dataBlock = getObjectOr(expData, blockName, new HashMap());
return getObjectOr(dataBlock, dataListName, new ArrayList<HashMap>());
} | java |
public Set<CellFiller> entries() {
return FluentIterable.from(table.cellSet())
.transformAndConcat(CollectionUtils.<List<CellFiller>>TableCellValue())
.toSet();
} | java |
public <SignatureType> BrokenDownProvenancedConfusionMatrix<SignatureType, CellFiller>
breakdown(Function<? super CellFiller, SignatureType> signatureFunction,
Ordering<SignatureType> keyOrdering) {
final Map<SignatureType, Builder<CellFiller>> ret = Maps.newHashMap();
// a more efficient implementatio... | java |
public static String getContentType(String filename) {
final ContentFileTypeMap map = ensureContentTypeManager();
return map.getContentType(filename);
} | java |
public static String getFormatVersion(File filename) {
final ContentFileTypeMap map = ensureContentTypeManager();
return map.getFormatVersion(filename);
} | java |
public static boolean isImage(String mime) {
try {
final MimeType type = new MimeType(mime);
return IMAGE.equalsIgnoreCase(type.getPrimaryType());
} catch (MimeTypeParseException e) {
//
}
return false;
} | java |
public static boolean isContentType(URL filename, String desiredMimeType) {
final ContentFileTypeMap map = ensureContentTypeManager();
return map.isContentType(filename, desiredMimeType);
} | java |
public static Method getPublicMethod(Class<?> clazz, String methodName, Class<?>[] argTypes) {
assertObjectNotNull("clazz", clazz);
assertStringNotNullAndNotTrimmedEmpty("methodName", methodName);
return findMethod(clazz, methodName, argTypes, VisibilityType.PUBLIC, false);
} | java |
public static Object invoke(Method method, Object target, Object[] args) {
assertObjectNotNull("method", method);
try {
return method.invoke(target, args);
} catch (InvocationTargetException e) {
Throwable t = e.getCause();
if (t instanceof RuntimeException) {... | java |
public static void assertStringNotNullAndNotTrimmedEmpty(String variableName, String value) {
assertObjectNotNull("variableName", variableName);
assertObjectNotNull("value", value);
if (value.trim().length() == 0) {
String msg = "The value should not be empty: variableName=" + variab... | java |
public static Optional<Element> nextSibling(final Element element, final String name) {
for (Node childNode = element.getNextSibling(); childNode != null;
childNode = childNode.getNextSibling()) {
if (childNode instanceof Element && ((Element) childNode).getTagName()
.equalsIgnoreCase(name)... | java |
public static String prettyPrintElementLocally(Element e) {
final ImmutableMap.Builder<String, String> ret = ImmutableMap.builder();
final NamedNodeMap attributes = e.getAttributes();
for (int i = 0; i < attributes.getLength(); ++i) {
final Node attr = attributes.item(i);
ret.put(attr.getNodeNam... | java |
public static Point1d convert(Tuple1d<?> tuple) {
if (tuple instanceof Point1d) {
return (Point1d) tuple;
}
return new Point1d(tuple.getSegment(), tuple.getX(), tuple.getY());
} | java |
@Pure
public static GeodesicPosition EL2_WSG84(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2E_N,
LAMBERT_2E_C,
LAMBERT_2E_XS,
LAMBERT_2E_YS);
return NTFLambdaPhi_WSG84(ntfLambdaPhi.getX(), ntfLambdaPhi.getY());
} | java |
@Pure
public static Point2d EL2_L2(double x, double y) {
return new Point2d(x, y + (LAMBERT_2E_YS - LAMBERT_2_YS));
} | java |
@Pure
public static Point2d EL2_L3(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2E_N,
LAMBERT_2E_C,
LAMBERT_2E_XS,
LAMBERT_2E_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_3_N,
LAMBERT_3_C,
LAMBERT_... | java |
@Pure
public static GeodesicPosition L1_WSG84(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_1_N,
LAMBERT_1_C,
LAMBERT_1_XS,
LAMBERT_1_YS);
return NTFLambdaPhi_WSG84(ntfLambdaPhi.getX(), ntfLambdaPhi.getY());
} | java |
@Pure
public static Point2d L1_EL2(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_1_N,
LAMBERT_1_C,
LAMBERT_1_XS,
LAMBERT_1_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_2E_N,
LAMBERT_2E_C,
LAMBERT_2E... | java |
@Pure
public static Point2d L1_L3(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_1_N,
LAMBERT_1_C,
LAMBERT_1_XS,
LAMBERT_1_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_3_N,
LAMBERT_3_C,
LAMBERT_3_XS,... | java |
@Pure
public static Point2d L1_L4(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_1_N,
LAMBERT_1_C,
LAMBERT_1_XS,
LAMBERT_1_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_4_N,
LAMBERT_4_C,
LAMBERT_4_XS,... | java |
@Pure
public static GeodesicPosition L2_WSG84(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2_N,
LAMBERT_2_C,
LAMBERT_2_XS,
LAMBERT_2_YS);
return NTFLambdaPhi_WSG84(ntfLambdaPhi.getX(), ntfLambdaPhi.getY());
} | java |
@Pure
public static Point2d L2_EL2(double x, double y) {
return new Point2d(x, y - (LAMBERT_2E_YS - LAMBERT_2_YS));
} | java |
@Pure
public static Point2d L2_L1(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2_N,
LAMBERT_2_C,
LAMBERT_2_XS,
LAMBERT_2_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_1_N,
LAMBERT_1_C,
LAMBERT_1_XS,... | java |
@Pure
public static Point2d L2_L3(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2_N,
LAMBERT_2_C,
LAMBERT_2_XS,
LAMBERT_2_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_3_N,
LAMBERT_3_C,
LAMBERT_3_XS,... | java |
@Pure
public static Point2d L2_L4(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2_N,
LAMBERT_2_C,
LAMBERT_2_XS,
LAMBERT_2_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_4_N,
LAMBERT_4_C,
LAMBERT_4_XS,... | java |
@Pure
public static Point2d L2_L93(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_2_N,
LAMBERT_2_C,
LAMBERT_2_XS,
LAMBERT_2_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_93_N,
LAMBERT_93_C,
LAMBERT_93... | java |
@Pure
public static GeodesicPosition L3_WSG84(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_3_N,
LAMBERT_3_C,
LAMBERT_3_XS,
LAMBERT_3_YS);
return NTFLambdaPhi_WSG84(ntfLambdaPhi.getX(), ntfLambdaPhi.getY());
} | java |
@Pure
public static Point2d L3_L4(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_3_N,
LAMBERT_3_C,
LAMBERT_3_XS,
LAMBERT_3_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_4_N,
LAMBERT_4_C,
LAMBERT_4_XS,... | java |
@Pure
public static Point2d L3_L93(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_3_N,
LAMBERT_3_C,
LAMBERT_3_XS,
LAMBERT_3_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_93_N,
LAMBERT_93_C,
LAMBERT_93... | java |
@Pure
public static GeodesicPosition L4_WSG84(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_4_N,
LAMBERT_4_C,
LAMBERT_4_XS,
LAMBERT_4_YS);
return NTFLambdaPhi_WSG84(ntfLambdaPhi.getX(), ntfLambdaPhi.getY());
} | java |
@Pure
public static Point2d L4_EL2(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_4_N,
LAMBERT_4_C,
LAMBERT_4_XS,
LAMBERT_4_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_2E_N,
LAMBERT_2E_C,
LAMBERT_2E... | java |
@Pure
public static GeodesicPosition L93_WSG84(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_93_N,
LAMBERT_93_C,
LAMBERT_93_XS,
LAMBERT_93_YS);
return NTFLambdaPhi_WSG84(ntfLambdaPhi.getX(), ntfLambdaPhi.getY());
} | java |
@Pure
public static Point2d L93_EL2(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_93_N,
LAMBERT_93_C,
LAMBERT_93_XS,
LAMBERT_93_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_2E_N,
LAMBERT_2E_C,
LAMBE... | java |
@Pure
public static Point2d L93_L1(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_93_N,
LAMBERT_93_C,
LAMBERT_93_XS,
LAMBERT_93_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_1_N,
LAMBERT_1_C,
LAMBERT_... | java |
@Pure
public static Point2d L93_L4(double x, double y) {
final Point2d ntfLambdaPhi = NTFLambert_NTFLambdaPhi(x, y,
LAMBERT_93_N,
LAMBERT_93_C,
LAMBERT_93_XS,
LAMBERT_93_YS);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_4_N,
LAMBERT_4_C,
LAMBERT_... | java |
@SuppressWarnings({"checkstyle:parametername", "checkstyle:localfinalvariablename"})
private static Point2d NTFLambert_NTFLambdaPhi(double x, double y, double n, double c, double Xs, double Ys) {
// Several constants from the IGN specifications
//Longitude in radians of Paris (2°20'14.025" E) from Greenwich
fina... | java |
@SuppressWarnings({"checkstyle:magicnumber", "checkstyle:localfinalvariablename", "checkstyle:localvariablename"})
private static GeodesicPosition NTFLambdaPhi_WSG84(double lambda_ntf, double phi_ntf) {
// Geographical coordinate NTF (lamda_ntf,phi_ntf)
// -> Cartesian coordinate NTF (x_ntf,y_ntf,z_ntf)
// ALG00... | java |
@Pure
public static Point2d WSG84_EL2(double lambda, double phi) {
final Point2d ntfLambdaPhi = WSG84_NTFLamdaPhi(lambda, phi);
return NTFLambdaPhi_NTFLambert(
ntfLambdaPhi.getX(), ntfLambdaPhi.getY(),
LAMBERT_2E_N,
LAMBERT_2E_C,
LAMBERT_2E_XS,
LAMBERT_2E_YS);
} | java |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.