myeclipse2017+windows使用笔记

myeclipse:

快速创建spingboot项目:new --> spring starter project

打包springboot项目,target上层目录:  mvn clean package

指定springboot项目按照某种环境运行: java -jar ...jar --spring.profiles.active=dev;(application-dev.properties 配置文件生效)

修改tomcat启动时间:修改 workspace\.metadata\.plugins\org.eclipse.wst.server.core\servers.xml文件,把 start-timeout="45" 改为 start-timeout="1000" 或者更长,重启myeclipse既可

设置临时jdk环境  set path=D:\developertool\jdk\jdk7\bin          到bin目录

导入maven项目时:One or more constraints have not been satisfied.Spring 4.1 requires Java 1.6 or newer.

The solution is I have to goto to the ".settings" folder which is at the project location and deleted "org.eclipse.wst.common.project.facet.core.xml" file and restarted the process again. This time it worked

这个从网上照的一个办法,比较好用,有作用。

就是删除掉.setting文件下的这个文件。然后将项目从MyEcplise中删掉,再Import进去,然后,发现项目不能被Tomcat识别了。

然后右键项目-->properties-->project Facts 将项目的web版本,java版本,hibernate版本等一并都选择好,再回来项目就好了。

The prefix "p" for attribute "p:prefix" associated with an element type "bean" is not bound.

意思是: 前缀“p”属性“p:jdbc。driverClassName”与某个元素类型相关“bean”却不被捆绑

这是因为在使用XML Schema作为配置文件的语义约束时,没有添加下面这条语句:

xmlns:p="http://www.springframework.org/schema/p"

在spring中使用cache机制进行操作,添加后报错:

The prefix "cache" for element "cache:annotation-driven" is not bound.

错误原因: 我们在定义申明AOP的时候。。没有加载schema

解决方案:xml配置文件中加入:xmlns:cache="http://www.springframework.org/schema/cache"

xsi:schemaLocation=“

        xxxx

        http://www.springframework.org/schema/cache

        http://www.springframework.org/schema/cache/spring-cache.xsd”

windows7 端口查看以及杀死进程释放端口:

输入命令:netstat -ano,列出所有端口的情况

查看被占用端口对应的PID,输入命令:netstat -aon|findstr "8080",回车,记下最后一位数字,即PID,

根据PID查看是哪个进程或者程序占用了8080端口,继续输入 tasklist|findstr "PID"

关闭进程,输入 taskkill /f /t /im QQ.exe

Ctrl+k 快速定位到下一个  Ctrl+Shift+k 快速定位到上一个  

Ctrl+D 删除当行     当光标在一行的两端时,按住shift+home/end可以选择当前行

Ctrl+L 定位在某行   ctrl+o:快速outline 列出当前类中的所有方法及属性

 ctrl+e:快速转换编辑器     Ctrl+M 最大化当前的Edit或View (再按则反之) 

Ctrl+Shift+S  保存所有未保存的文件。

Ctrl+Shift+R  查找没有编译的文件。

Ctrl+Shift+T  查找class文件。

Ctrl + t  显示当前接口的实现类

重写快捷键是    alt + shift + s

myeclipse自动生成相应对象接收返回值:

在你要自动生成返回值对象的那一行的末尾(注意一定要将光标点到最后),按Alt+Shift+L;

Run:运行   Ctrl+F11

Debug:调式  F11

MyEclipse 清除记录的工作空间:

windows--->preference--->general--->startup and shutdown--->workspace  选择不需要的目录remove即可。

myeclipse 编辑器由于行太长,光标自动跑到最左边的问题:

Preference -> File and Editors -> Common Editor Preferences  取消勾选 enable folding

 windows:

快捷键::F1帮助。F2:文件夹重命名。F3:搜索文件夹。F4:打开地址栏列表F5:刷新。F6:定位地址栏。F8:调出启动顺序。F11:全屏显示。F12:另存为。删除:Del。永久删除:shift+del

猜你喜欢

转载自blog.csdn.net/today__tomorrow/article/details/80524381