`
文章列表
  http://vansande.org/2015/03/26/intellij_idea_live_templates_for_unit_testing/
https://www.journaldev.com/2856/java-jvm-memory-model-memory-management-in-java
#!/bin/bash contains() { string="$1" substring="$2" if test "${string#*$substring}" != "$string" then return 0 # $substring is in $string else return 1 # $substring is not in $string fi } file=$1 de ...
Path path = Paths.get(getClass().getClassLoader() .getResource("fileTest.txt").toURI()); //relative to the class String content = new String(Files.readAllBytes(path)); try (Stream<String> stream = Files.lines(Paths.get(fileName))) { stream.forEach(System. ...
Put this in the profile. If you use fish, put it in ~/.config/fish/config.fish   ln /Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl /usr/local/bin/st  
很容量找到怎么在tomcat中远程调试的文章。如 http://stackoverflow.com/questions/6733849/remote-debugging-in-intellij-tomcat   但是这种调试只能在tomcat启动完成之后才能开启。但是我们有时想调试tomcat启动时用到的代码,如一应用的初始化代码。其实很简单。   <jvmarg line="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=${debug-port}"/>   只需要把suspend ...
The best way I have found to persistently add a path to your $PATH is   set-U fish_user_paths $fish_user_paths ~/path/name   This prepends to $PATH. And since it's persistent, the path stays in $PATH on shell restarts.
building microservices summary

Integer Break

    public class IntegerBreak { public int integerBreak(int n) { if (n == 2) { return 1; } if (n == 3) { return 2; } if (n % 3 == 1) { int p = n / 3; return (int) Math.pow(3, p - 1) * 4; ...
    public class Solution { public int lengthOfLIS(int[] nums) { if(nums.length==0){ return 0; } int[] lens= new int[nums.length]; lens[0]=1; int max=1; for(int i=1;i<nums.length;i++){ for (int j = 0; ...
  import java.util.*; public class Solution { public List<Integer> topKFrequent(int[] nums, int k) { HashMap<Integer, Integer> numberOccur = getNumOccur(nums); PriorityQueue<Integer> priorityQueue = new PriorityQueue<>((o1, o2) -> numberOcc ...
Create an environment.plist file in ~/Library/LaunchAgents/ with this content: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version=" ...
1. Switch to root 2. sudo qemu-img resize images/win2008.img +20G 3. Start windows vm and go to server manager 4. Server Manager->Storage->Diskmanagement 5. Extend volume of C with the added disk space
  http://bartwullems.blogspot.com/2012/03/nhibernate-eager-fetching.html   NHibernate eager fetching   NHibernate supports the concept of eager fetching for a long time. However there are some things to consider when you start using this with the out-of-the-box NHibernate Linq provider. Let’s ...
  http://www.cnblogs.com/lmule/archive/2010/08/18/1802774.html
Global site tag (gtag.js) - Google Analytics