标签: intellij-13

Scala中的IDEA 13正则表达式检查程序

IDEA中有很酷的功能来检查你的Java正则表达式.
当您点击所选模式的Alt+时Enter,您会得到:

图像链接

如果您选择Check RegExp,您会得到以下内容:

图像链接

但是如果你使用Scala尝试相同的东西,就没有Check RegExp选项.我试着打Alt+ Enter每个以下行的代码:

val myRegex = """\w""".r
val myRegex2:Pattern = Pattern.compile("""\w""")
val myregex3 = new Regex("""\w""")
Run Code Online (Sandbox Code Playgroud)

但没有显示Check RegExp选项.知道如何"启用"此功能以使用Scala吗?

regex scala intellij-idea intellij-13

5
推荐指数
1
解决办法
762
查看次数

有没有办法在 Intellij IDEA 中查看所有 @RequestMapping URL 的映射?

有没有办法将所有@RequestMapping 注释视为所有请求/URL 的映射,理想情况下可以快速链接到处理 URL 的任何控制器/方法?

在 Spring 2(注释之前)XML 配置(SimpleUrlHandlerMapping)可以用作这样的参考,现在使用带注释的控制器除了搜索代码库之外还有其他方法吗?

spring spring-mvc intellij-idea spring-boot intellij-13

5
推荐指数
1
解决办法
6460
查看次数

Intellij代码完成,显示方法/构造函数参数类型和变量名称

我发现这非常令人讨厌,当你已经编写了第一个参数时,你经常无法找到方法和构造函数的参数签名.

相反,Intellij将在您的上下文中显示可用的变量.这很好,但不是第一个prio.我想看到方法/构造函数的签名.

这导致您始终必须继续删除和CTRL + SPACE以查看签名.

有没有解决这个问题的方法?

java intellij-idea intellij-plugin intellij-13

5
推荐指数
2
解决办法
2477
查看次数

Intellij IDEA,控制上一页,下一页滚动大小

我对intellij中向上翻页,向下翻页的滚动行为不满意。感觉不对。总是感觉好像我超出了范围。

是否可以调整上一页,下一页的滚动大小?也许到半页或类似的页面。

intellij-idea intellij-13 intellij-14

5
推荐指数
2
解决办法
1187
查看次数

IntelliJ在打字时编译时将.class文件放在哪里

IntelliJ是否一直在编译,因为它在出现错误时会用红色波浪线告诉我?(除了自动完成功能)还是在进行某种伪造的编译?

如果它正在进行合法编译,它将这些编译的类放在哪里?我想将我的JRebel指向该目录而不是单个模块目标文件夹.

java intellij-idea jrebel intellij-13

4
推荐指数
2
解决办法
8182
查看次数

scalatest在intellij 13.1中不起作用

我似乎无法让Intellij 13.1运行我的测试.我创建了一个简单的项目来尝试和隔离问题,但它也没有在那里工作.这是我的设置:

  • Intellij 13.1针对JDK 1.6(正在使用的java库需要)
  • SBT支持scala 2.10项目
  • 最新的scalatest(libraryDependencies + ="org.scalatest"%"scalatest_2.11"%"2.2.1"%"test")

这是sut:

object Calc {
  def add(a: Int, b: Int) = {
    a + b
  }
}
Run Code Online (Sandbox Code Playgroud)

这是测试:

import org.scalatest.FunSuite

class Calc$Test extends FunSuite {
  test("two number should add") {
    assert(Calc.add(2, 5) == 7)
  }
}
Run Code Online (Sandbox Code Playgroud)

这是我得到的错误:

错误:scalac:编译时:/Users/test-user/Development/temp/sample/src/test/scala/Calc$Test.scala在阶段:typer库版本:版本2.10.4编译器版本:版本2.10.4重建args:-nobootcp -javabootclasspath:-classpath /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/deploy.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents /Home/lib/dt.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/javaws.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents /Home/lib/jce.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/jconsole.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents /Home/lib/management-agent.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/plugin.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk /Contents/Home/lib/sa-jdi.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Classes/charsets.jar:/System/Library/Java/Jav aVirtualMachines/1.6.0.jdk /内容/班/ classes.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Classes/jsse.jar:/System/Library/Java/JavaVirtualMachines/1.6. 0.jdk /内容/班/ ui.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/ext/apple_provider.jar:/System/Library/Java/JavaVirtualMachines/1.6. 0.jdk /内容/首页/ lib/ext目录/ dnsns.jar:/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/ext/localedata.jar:/系统/库/ Java的/ JavaVirtualMachines/1.6.0.jdk /内容/首页/ lib/ext目录/程序(sunjce_provider.jar):/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/ext/sunpkcs11.jar:/用户/测试用户/开发/温度/样品/目标/阶-2.10 /测试类:/Users/test-user/Development/temp/sample/target/scala-2.10/classes:/Users/test-user/.sbt /boot/scala-2.10.4/lib/scala-library.jar:/Users/test-user/.ivy2/cache/org.scala-lang/scala-library/jars/scala-library-2.11.2.jar :/Users/test-user/.ivy2/cache/org.scala-lang/scala-reflect/ja RS /斯卡拉 - 反射 - 2.11.2.jar:/Users/test-user/.ivy2/cache/org.scala-lang.modules/scala-xml_2.11/bundles/scala-xml_2.11-1.0.2.罐子:/Users/test-user/.ivy2/cache/org.scalatest/scalatest_2.11/bundles/scalatest_2.11-2.2.1.jar:/Users/test-user/.sbt/boot/scala-2.10. 4/lib/scala-reflect.jar:/Users/test-user/.sbt/boot/scala-2.10.4/lib/scala-compiler.jar对typer的最后一棵树:Apply(method ==)symbol:method = = …

scala intellij-idea scalatest intellij-13

4
推荐指数
1
解决办法
2389
查看次数

Intellij IDEA 和 Maven,在每个小更改上禁用读取 pom.xml,即使没有保存

这导致 intellij 变得缓慢并冻结,这非常烦人。

看起来好像它分析了类似于 pom.xml 的其他文件,导致其他地方也冻结。

可以禁用此功能吗?

intellij-idea intellij-13

4
推荐指数
1
解决办法
3913
查看次数

更改build.sbt以使ScalaTest测试能够与Scala Play一起运行

我在这里关注文档,这似乎根本不起作用; 但我甚至不确定我在这里做错了什么.

首先,只是在project/Build.scala文件中添加给定的片段会导致编译错误; 所以这不是一个开始.将其包装在扩展的对象内Build(如在SBT示例中)不会导致编译错误,但不会运行测试.

最后,我已将以下内容添加到我的 build.sbt

libraryDependencies ++= Seq(
    "org.scalatestplus" %% "play" % "1.0.0" % "test",
    ...
Run Code Online (Sandbox Code Playgroud)

这稍微好一点,但在IntelliJ中,我ApplicationSpec有各种编译错误:

import org.scalatestplus.play._

import scala.collection.mutable.Stack

class ApplicationSpec extends PlaySpec {

  "A Stack" must {
    "pop values in last-in-first-out order" in {
      val stack = new Stack[Int]
      stack.push(1)
      stack.push(2)
      stack.pop() mustBe 2
      stack.pop() mustBe 1
    }
    "throw NoSuchElementException if an empty stack is popped" in {
      val emptyStack = new Stack[Int]
      a [NoSuchElementException] must be thrownBy …
Run Code Online (Sandbox Code Playgroud)

scala scalatest playframework intellij-13

4
推荐指数
1
解决办法
1585
查看次数

显示错误:未知的HTML标记

所以我刚开始使用Phpstorm,我正在尝试"更正"我的代码,因此IDE没有错误.我在下面有以下方法,所有我的xml标签都突出显示'未知HTML标记'

纠正这个问题的最佳方法是什么?

private function generate_qbxml_CustomerAddRq($requestID=0){
                /** requestID is used when multiple requests are called in order to match the request to the response.
                    requestID's should be incremented as they are called. Currently not implimented. **/
                $qbxml  = '';
                $qbxml .= '<?xml version="1.0" encoding="utf-8"?>';
                $qbxml .= '<?qbxml version="2.0"?>';
                $qbxml .= '<QBXML>';
                $qbxml .=   '<QBXMLMsgsRq onError="stopOnError">';
                $qbxml .=       '<CustomerAddRq requestID="'.$requestID.'">';
                $qbxml .=           '<CustomerAdd>';
                $qbxml .=               '<Name>'.$this->Name.'</Name>'; //Name is a mandatory field. Add a check for this.
                /** For all optional values …
Run Code Online (Sandbox Code Playgroud)

phpstorm intellij-13

4
推荐指数
2
解决办法
3444
查看次数

Lua 和 IntelliJ

有人知道使用 IntelliJ 编写 Lua 的好插件吗?我正在使用sylvanaar的一个,但它非常缓慢。

更新:由于代码样式而变慢。

更新 2:我放弃在 IntelliJ 上使用 LUA 我发现https://studio.zerobrane.com/更适合我的需要,而且速度非常快。

lua intellij-idea intellij-13 intellij-14

4
推荐指数
2
解决办法
6250
查看次数