- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中org.geotools.resources.XArray
类的一些代码示例,展示了XArray
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XArray
类的具体详情如下:
包路径:org.geotools.resources.XArray
类名称:XArray
[英]Simple operations on arrays. This class provides a central place for inserting and deleting elements in an array, as well as resizing the array. This class may be removed if JavaSoft provide some language construct functionally equivalent to C/C++'s realloc.
[中]对数组的简单操作。此类为插入和删除数组中的元素以及调整数组大小提供了一个中心位置。如果JavaSoft提供了一些功能等同于C/C++的realloc的语言构造,则可以删除此类。
代码示例来源:origin: org.geotools/gt2-coverageio
/**
* Libre la mmoire rserve en trop. Cette mthode peut tre appele
* lorsqu'on a termin de lire les donnes et qu'on veut les conserver
* en mmoire pendant encore quelque temps.
*/
public void trimToSize() {
if (data != null) {
data = XArray.resize(data, upper);
}
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Inserts spaces into the middle of an array. These "spaces" will be made up of elements
* initialized to zeros.
*
* @param array Array in which to insert spaces.
* @param index Index where the first space should be inserted. All {@code array} elements
* having an index equal to or higher than {@code index} will be moved forward.
* @param length Number of spaces to insert.
* @return Array containing the {@code array} elements with the additional space
* inserted, or {@code array} if {@code length} is 0.
*/
public static byte[] insert(final byte[] array, final int index, final int length) {
return doInsert(array, index, length);
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Removes elements from the middle of an array.
*
* @param array Array from which to remove elements.
* @param index Index of the first element to remove from the given {@code array}.
* @param length Number of elements to remove.
* @return Array with the same elements than the given {@code array} except for the
* removed elements, or {@code array} if {@code length} is 0.
*/
public static double[] remove(final double[] array, final int index, final int length) {
return doRemove(array, index, length);
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Returns an array containing the same elements as the given {@code array} but
* specified {@code length}, truncating or padding with zeros if necessary.
*
* @param array Array to copy.
* @param length Length of the desired array.
* @return A new array of the requested length, or {@code array} if the original
* array already have the requested length.
*/
public static int[] resize(final int[] array, final int length) {
return doResize(array, length);
}
代码示例来源:origin: org.geotools/gt-coverage
expectedTarget = expectedSource * scale + offset;
breakpoints[i][0] = sourceBreakpoints = XArray.resize(sourceBreakpoints, jbp);
breakpoints[i][1] = targetBreakpoints = XArray.resize(targetBreakpoints, jbp);
assert XArray.isSorted(sourceBreakpoints);
代码示例来源:origin: org.geotools/gt2-widgets-swing
/**
* Set the foreground and background colors for messages of the specified level.
* The specified colors will apply on any messages of level {@code level} or
* greater, up to the next level set with an other call to {@code setLevelColor(...)}.
*
* @param level The minimal level to set color for.
* @param foreground The foreground color, or {@code null} for the default color.
* @param background The background color, or {@code null} for the default color.
*/
public void setLevelColor(final Level level, final Color foreground, final Color background) {
final int value = level.intValue();
int i = Arrays.binarySearch(levelValues, value);
if (i >= 0) {
i *= 2;
levelColors.set(i+0, foreground);
levelColors.set(i+1, background);
} else {
i = ~i;
levelValues = XArray.insert(levelValues, i, 1);
levelValues[i] = value;
i *= 2;
levelColors.add(i+0, foreground);
levelColors.add(i+1, background);
}
assert XArray.isSorted(levelValues);
assert levelValues.length*2 == levelColors.size();
}
代码示例来源:origin: org.geotools/gt-metadata
children = XArray.insert(children, i, 1);
children[i] = new Logging(logging, name);
logging.children = children;
代码示例来源:origin: org.geotools/gt2-coverage
/**
* Removes an observer. If the observer was not registered, nothing happens.
* If the observer was registered for multiple notifications, it will now be
* registered for one fewer.
*/
public synchronized void removeTileObserver(final TileObserver observer) {
if (observers != null) {
for (int i=observers.length; --i>=0;) {
if (observers[i] == observer) {
observers = (TileObserver[]) XArray.remove(observers, i, 1);
break;
}
}
}
}
代码示例来源:origin: bcdev/beam
if (XArray.allEquals(background, 0)) {
borderExtender = BorderExtender.createInstance(BorderExtender.BORDER_ZERO);
} else {
代码示例来源:origin: org.geotools/gt-metadata
/**
* Returns an array containing the same elements as the given {@code array} but
* specified {@code length}, truncating or padding with zeros if necessary.
*
* @param array Array to copy.
* @param length Length of the desired array.
* @return A new array of the requested length, or {@code array} if the original
* array already have the requested length.
*/
public static double[] resize(final double[] array, final int length) {
return doResize(array, length);
}
代码示例来源:origin: org.geotools/gt2-metadata
children = (Logging[]) XArray.insert(children, i, 1);
children[i] = new Logging(logging, name);
logging.children = children;
代码示例来源:origin: org.geotools/gt2-widgets-swing
/**
* Removes an editor from the list of those which display the
* coordinates of the visor.
*
* @param editor Editor to remove.
*/
public synchronized void removeEditor(final JComponent editor) {
if (editors != null) {
for (int i = 0; i < editors.length; i++) {
if (editors[i].editor == editor) {
editors = (Control[]) XArray.remove(editors, i, 1);
/*
* In principal, there should be no more objects to
* remove from the table. But we let the loop continue
* anyway, just in case...
*/
}
}
if (editors.length == 0) {
editors = null;
}
}
}
代码示例来源:origin: senbox-org/s2tbx
if (XArray.allEquals(background, 0)) {
borderExtender = BorderExtender.createInstance(BorderExtender.BORDER_ZERO);
} else {
代码示例来源:origin: org.geotools/gt2-coverage
/**
* Adds an observer. This observer will be notified everytime a tile initially empty become
* available. If the observer is already present, it will receive multiple notifications.
*/
public synchronized void addTileObserver(final TileObserver observer) {
if (observer != null) {
if (observers == null) {
observers = new TileObserver[] {observer};
} else {
final int length = observers.length;
observers = (TileObserver[]) XArray.resize(observers, length+1);
observers[length] = observer;
}
}
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Inserts spaces into the middle of an array. These "spaces" will be made up of elements
* initialized to zeros.
*
* @param array Array in which to insert spaces.
* @param index Index where the first space should be inserted. All {@code array} elements
* having an index equal to or higher than {@code index} will be moved forward.
* @param length Number of spaces to insert.
* @return Array containing the {@code array} elements with the additional space
* inserted, or {@code array} if {@code length} is 0.
*/
public static int[] insert(final int[] array, final int index, final int length) {
return doInsert(array, index, length);
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Returns an array containing the same elements as the given {@code array} but
* specified {@code length}, truncating or padding with zeros if necessary.
*
* @param array Array to copy.
* @param length Length of the desired array.
* @return A new array of the requested length, or {@code array} if the original
* array already have the requested length.
*/
public static boolean[] resize(final boolean[] array, final int length) {
return doResize(array, length);
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Removes elements from the middle of an array.
*
* @param array Array from which to remove elements.
* @param index Index of the first element to remove from the given {@code array}.
* @param length Number of elements to remove.
* @return Array with the same elements than the given {@code array} except for the
* removed elements, or {@code array} if {@code length} is 0.
*/
public static int[] remove(final int[] array, final int index, final int length) {
return doRemove(array, index, length);
}
代码示例来源:origin: org.geotools/gt-metadata
changers = XArray.insert(changers, i, 1);
changers[i] = converter;
代码示例来源:origin: org.geotools/gt2-widgets-swing
/**
* Makes sure that the {@link #visibles} array has the specified capacity.
*/
private void ensureCapacity(final int capacity) {
if (visibles.length < capacity) {
visibles = XArray.resize(visibles, Math.max(size*2, capacity));
}
}
代码示例来源:origin: org.geotools/gt-metadata
/**
* Inserts spaces into the middle of an array. These "spaces" will be made up of elements
* initialized to {@code false}.
*
* @param array Array in which to insert spaces.
* @param index Index where the first space should be inserted. All {@code array} elements
* having an index equal to or higher than {@code index} will be moved forward.
* @param length Number of spaces to insert.
* @return Array containing the {@code array} elements with the additional space
* inserted, or {@code array} if {@code length} is 0.
*/
public static boolean[] insert(final boolean[] array, final int index, final int length) {
return doInsert(array, index, length);
}
我正在寻找外行人对计算机硬件和组织的介绍。以下是我想讨论的一些主题。 Brief intro to electronics. Gates and state machines, intro to re
有没有人在 Visual Basic 2010 中看到过这个错误,如果有的话......关于如何解决它的任何想法? 错误是 module 'Resources' and module 'Resourc
这个问题在这里已经有了答案: Why ?attr/colorAccent dose not work below lollipop version? (2 个答案) 关闭 5 年前。 我收到以下错误
我正在尝试通过 ring 学习 clojure 网络开发和 compojure我有点不清楚 compojure.route/resources 和 ring.middleware.resource/w
是否必须放置内部 try-with-resources 或其中一个 try-with-resources 中的所有内容都会自动关闭? try (BasicDataSource ds = Bas
我有一本包含多个食谱的 Chef 食谱,用于安装服务。 Chef-client 的工作方式是每 15 分钟(或其他固定时间间隔)重新收敛一次。现在我的食谱的第一步是停止服务,所以服务将每 15 分钟停
我有资源组“MyResources”,其中包含 4 个资源: AppService - 我的服务器, AppServicePlan - MyServerWestEuFarm, ApplicationI
我有资源组“MyResources”,其中包含 4 个资源: AppService - 我的服务器, AppServicePlan - MyServerWestEuFarm, ApplicationI
我有一个返回 ResponseEntity 的休息终点. 需要检查如何在 Swagger 规范中创建这种类型的响应。这里包中的资源是 org.springframework.core.io.Resou
In my azure portal I have 6 separate applications, I have to list all of the employed resources u
In my azure portal I have 6 separate applications, I have to list all of the employed resources u
我有一个问题,设计师不会显示表单。它失败,错误 Designer 给出警告,如下所示: 我该如何解决这个问题? 最佳答案 您似乎缺少在应用程序中加载此表单所需的项目 资源 . 您可以访问 资源右键单击
我是 angularJS 世界的新手,我可能误解了一些东西。 我的应用程序使用 Controller 、指令和服务,所有这些都运行完美,直到我使用带有 $resource 的服务,然后出现“冲突”或其
我在 Unity3D 工作。 我使用 Resources.LoadAll(path);加载文件夹和子文件夹中的所有项目。执行此操作后,我想获取对象的子文件夹名称或完整路径。这可能吗? 并且不建议使用
我需要监控每个客户端环境(一个订阅、多个资源组)的 Azure 支出。在我的研究中,我发现了 2 个可以使用的 API: 资源费率卡( https://msdn.microsoft.com/fr-fr
在 RDF 1.1 XML 语法文档中 rdf:resource 在定义 Empty Property Elements 时用作缩写形式: When a predicate arc in an RDF
这是一种常见的情况,我们需要在用户更新/创建一些数据后向用户显示错误/成功消息,我们如何在 AngularJS 中实现它? 我想添加回调但找不到解决方案。使用 $http.post().success
我正在使用 android studio 作为 IDE 开发一个 android 应用程序。 我的问题是: 如何在构建APK过程中排除某个目录下的某些文件? 在我的例子中,我想从构建中排除一些图像,因
在编译我的 Visual Studio C# 项目时,出现以下错误: 在“Resources”参数中多次指定项目“obj\Debug\SampleProject.Forms.MDIMain.resou
使用 CoffeeScript、Angular 和 $resource,我创建了以下工厂: angular.module('myapp', ['ngResource']).factory 'MyObj
我是一名优秀的程序员,十分优秀!