首页 \ 问答 \ lucene大于(lucene larger than)

lucene大于(lucene larger than)

你们中的任何人都知道如何搜索所有大于指定数字的数字吗?

例如:所有文档编号> 65

我尝试过:documentNumber:[65 TO *]但是我收到异常,因为lucene期望解析一个没有*的数字。

提前致谢!


Does anybody of you guys know how to search all the numbers larget than a specified one?

for example: all the document number > 65

i tried like: documentNumber: [65 TO *] but i receive exception, as lucene expected to parse a number there not a *.

Thanks in advance!


原文:https://stackoverflow.com/questions/1472724
更新时间:2022-05-05 12:05

最满意答案

好的,在你的屏幕(gameScreen和另一个)中删除“extends Game”,只留下工具屏幕。

然后,而不是像gameScreen中那样使用setScreen(game2)。 像这样用它:

game.setScreen(game2)//添加“游戏”。

多数民众赞成因为你的屏幕不会从游戏延伸,但你在该领域得到了游戏,所以你可以从中使用它。

并且仅作为额外:不要将另一个实例称为“game2”,因为它不是游戏。 并且不要使用小写字母来开始类的名称(gameScreen应该是GameScreen),但这只是约定,如果你这样做,由你决定。


Ok, in your screens (gameScreen and Another) delete "extends Game", only leave implements Screen.

Then instead of using setScreen(game2) like that in gameScreen. Use it like this:

game.setScreen(game2) //add "game."

thats because your screen wont extend from game, but you get the game in that field, so you can use it from it.

And only as an extra: dont call the Another instance "game2" because it is not a game. And dont use lowercase letter to begin the name of a class (gameScreen should be GameScreen), but thats only convention, up to you if you do it.

相关问答

更多
  • 看起来你忘了设置输入处理器 Gdx.input.setInputProcessor(var); 您应该在MenuScreen show()方法中调用此方法。 这样引擎会知道你的输入处理器*。 代码如下所示: public class MenuScreen extends InputAdapter implements Screen { ... @Override public void show() { Gdx.input.setInputProcessor(t ...
  • 如果您希望应用程序捕获后退键而不是操作系统,那么您希望使用true而不是false作为setCatchBackKey方法的参数。 另见文档 : 设置是否应捕获Android上的BACK按钮。 这样可以防止应用暂停。 对桌面没有任何影响。 If you want your application to catch the back key instead of the OS, then you want to use true instead of false as argument of the setCa ...
  • 您只需在第二个屏幕上添加一个标志即可忽略第一个touchup事件。 private boolean isFirstTouchUp = true; 在touchup事件中,添加此代码, if(isFirstTouchUp){ isFirstTouchUp = false; }else{ // Do you touchup event here, } 希望我能帮到你:D You can simply add a flag on the second screen to ignore the first ...
  • 根据您希望何时完成,您需要致电: myStage.act(); 获取您要查找的输出的示例是: if(player.isDead()) { myStage.act(); } 但请注意,这不是转换屏幕的有效方法。 Depending on when you want it to be done, you need to call: myStage.act(); And an example to get the output your looking for would be: if(player ...
  • 任何LibGDX屏幕只不过是一种AndroidLauncher活动视图。 当您使用Interface打开任何其他活动时,具有LibGDX视图的Activity将暂停并在后台折叠。 您可以使用Intent从任何活动返回到Libgdx活动。 Intent intent = new Intent(this, AndroidLauncher.class); startActivity(intent); 或者可能通过finish()您可以返回上一个活动。 Any Screen of LibGDX is nothin ...
  • 好的,在你的屏幕(gameScreen和另一个)中删除“extends Game”,只留下工具屏幕。 然后,而不是像gameScreen中那样使用setScreen(game2)。 像这样用它: game.setScreen(game2)//添加“游戏”。 多数民众赞成因为你的屏幕不会从游戏延伸,但你在该领域得到了游戏,所以你可以从中使用它。 并且仅作为额外:不要将另一个实例称为“game2”,因为它不是游戏。 并且不要使用小写字母来开始类的名称(gameScreen应该是GameScreen),但这只是约 ...
  • 浏览代码并思考逻辑。 您遵循if-else语句并始终将SP添加到速度。 如此有效,您可以将该数学与if-else结合使用,从而产生以下等效结果: if (position.x > 2560) { velocity.add(0, 0, 0); } else { velocity.add(2 * SP, 0, 0); } velocity.scl(dt); position.add(velocity.x, 0, 0); ve ...
  • setGravity()方法确定将内容放置在AdView中的位置(在本例中为广告),而不是将AdView放置在其容器中的位置。 看起来你的容器是RelativeLayout,所以你应该能够设置新的LayoutParams而不是设置引力: RelativeLayout.LayoutParams adParams = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.WRAP_CONTENT, ...
  • 将渲染功能更改为: @Override public void render(float delta) { Gdx.gl.glClear(GL10.GL_COLOR_BUFFER_BIT); //clears the buffer CharSequence str = "Main Menu"; batch = new SpriteBatch(); font = new BitmapFont(); batch.begin(); font.d ...
  • 似乎问题来自处理skin 。 我在外部类中使用static Skin对象作为我的皮肤,所有需要该皮肤的类都使用它。 我的问题是我将皮肤放在其中一个屏幕上,这样可以处理所有其他课程所使用的皮肤。 我通过简单地创建一个dispose();来解决这个问题dispose(); 在类中保存我所有皮肤的方法,并在我退出游戏时处理它们。 It seems like the problem came from disposing the skin. I use a static Skin object in an exte ...

相关文章

更多

最新问答

更多
  • 您如何使用git diff文件,并将其应用于同一存储库的副本的本地分支?(How do you take a git diff file, and apply it to a local branch that is a copy of the same repository?)
  • 将长浮点值剪切为2个小数点并复制到字符数组(Cut Long Float Value to 2 decimal points and copy to Character Array)
  • OctoberCMS侧边栏不呈现(OctoberCMS Sidebar not rendering)
  • 页面加载后对象是否有资格进行垃圾回收?(Are objects eligible for garbage collection after the page loads?)
  • codeigniter中的语言不能按预期工作(language in codeigniter doesn' t work as expected)
  • 在计算机拍照在哪里进入
  • 使用cin.get()从c ++中的输入流中丢弃不需要的字符(Using cin.get() to discard unwanted characters from the input stream in c++)
  • No for循环将在for循环中运行。(No for loop will run inside for loop. Testing for primes)
  • 单页应用程序:页面重新加载(Single Page Application: page reload)
  • 在循环中选择具有相似模式的列名称(Selecting Column Name With Similar Pattern in a Loop)
  • System.StackOverflow错误(System.StackOverflow error)
  • KnockoutJS未在嵌套模板上应用beforeRemove和afterAdd(KnockoutJS not applying beforeRemove and afterAdd on nested templates)
  • 散列包括方法和/或嵌套属性(Hash include methods and/or nested attributes)
  • android - 如何避免使用Samsung RFS文件系统延迟/冻结?(android - how to avoid lag/freezes with Samsung RFS filesystem?)
  • TensorFlow:基于索引列表创建新张量(TensorFlow: Create a new tensor based on list of indices)
  • 企业安全培训的各项内容
  • 错误:RPC失败;(error: RPC failed; curl transfer closed with outstanding read data remaining)
  • C#类名中允许哪些字符?(What characters are allowed in C# class name?)
  • NumPy:将int64值存储在np.array中并使用dtype float64并将其转换回整数是否安全?(NumPy: Is it safe to store an int64 value in an np.array with dtype float64 and later convert it back to integer?)
  • 注销后如何隐藏导航portlet?(How to hide navigation portlet after logout?)
  • 将多个行和可变行移动到列(moving multiple and variable rows to columns)
  • 提交表单时忽略基础href,而不使用Javascript(ignore base href when submitting form, without using Javascript)
  • 对setOnInfoWindowClickListener的意图(Intent on setOnInfoWindowClickListener)
  • Angular $资源不会改变方法(Angular $resource doesn't change method)
  • 在Angular 5中不是一个函数(is not a function in Angular 5)
  • 如何配置Composite C1以将.m和桌面作为同一站点提供服务(How to configure Composite C1 to serve .m and desktop as the same site)
  • 不适用:悬停在悬停时:在元素之前[复制](Don't apply :hover when hovering on :before element [duplicate])
  • 常见的python rpc和cli接口(Common python rpc and cli interface)
  • Mysql DB单个字段匹配多个其他字段(Mysql DB single field matching to multiple other fields)
  • 产品页面上的Magento Up出售对齐问题(Magento Up sell alignment issue on the products page)