일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | |
7 | 8 | 9 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 |
- fragment
- JavaScript
- CSS사용법
- Android Apk
- java error
- android fragment
- Android
- apache gzip
- release unsigned
- android error
- FLUTTER
- DataTable
- spring
- 안드로이드
- css
- error
- Android Apk 이름
- Android Apk 이름 변경
- release Apk
- Java
- Eclipse
- Exception
- Firebase
- Program type already present
- MySQL
- Kotlin
- jQuery
- tomcat
- html
- R프로그래밍
- Today
- Total
목록Server (46)
selfstarter
Properties Some characters cannot be mapped using "ISO-8859-1" character encoding Error 다국어 Properties 저장 시 다음 에러 발생. 또 ISO-8859-1 인코딩을 한 상태였는데 다른사람은 이상없는데 내 자리만 다르게 인코딩됨. Some characters cannot be mapped using "ISO-8859-1" character encoding. Either change the encoding or remove the characters which are not supported by the ISO-8859-1 character encoding 1) 파일 message_vi.properties - Properties ..
Java Reflection으로 class 정보 가져오기 Reflection은 객체의 정보를 알아내는 기능을 가진 class이다 field에 setAccessible()함수 인자를 true로 줘야 접근이 가능하다 getField와 getDeclaredFields, getMethod와 getDeclaredMethod함수의 차이는 해당 class에서 선언된 함수, 필드만 가져올 땐 Declared 붙은 함수를 사용하고, 상속받은 class의 정보도 표시하고 싶을 때는 Declared가 없는 함수를 호출한다 public static String getInfo(Object obj) { StringBuilder builder = new StringBuilder(); builder.append("pakage nam..
Java instanceof example instanceof는 데이터의 자료형을 확인해서 데이터 자료형에 따라 각자 다른 처리를 다르게 할 때 자주 쓰인다 부모로 Object를 가지고 있는 DataType만 instanceof로 비교가 가능하다 Wrapper class가 아닌 기본 자료형 int도 Integer로 확인되는 걸 확인할 수 있다 상속을 한 class는 instanceof를 사용할 때 반드시 child class 형을 먼저 확인해야 한다. child class 보다 parent class가 먼저 있다면 parent class type으로 인식된다. 반드시 자식 class type을 먼저 체크하자 Example package javaTest; import java.util.ArrayList; ..
No enclosing instance of type Myani is accessible Error No enclosing instance of type Myani is accessible Code public class TestMain { public static void main(String[] args) { AAA aaa = new AAA(); } public class AAA { public AAA() { } }} Case main함수 내에 AAA class를 생성하는 코드에서 오류 발생 확인해 보니 static main은 static 이므로 이미 다른 class들 보다 먼저 생성되어져 메모리 상에 올라가 있다. 그런데 AAA class는 static class가 아니므로 메모리상에 없기 때문에 ..
non-static method 'getclass()' cannot be referenced from a static context 해결방법 Error non-static method 'getclass()' cannot be referenced from a static context Code public static final String className = getClass().getSimpleName().trim();Case class의 전역에서 사용하려고 했다. 그런데 getClass는 static Method가 아니므로 전역에서 사용할 수 없다. Soution 정적메소드가 아닌 getClass()말고 클래스이름.class을 쓰면 된다
Java split 공백도 배열에 추가되도록 하기 splite 함수의 두번째 인자는 limit인데 -1을 넣을 경우 공백도 array에 포함이 된다 아래 예제에서 limit값을 사용하지 않으면 result2배열에는 공백을 제외해서 length가 6개, result3은 length가 7개이다 splite 함수 두번째 인자로 -1을 주면 공백도 배열에 들어가서 result2, result3 length는 8개가 된다 Example Code String complete = "AAAA|BBB|CCC|DDD|EEE|FFF|GGG|HHH"; String complete_1 = "AAAA|BBB|CCC|DDD|EEE|FFF||HHH"; String complete_2 = "AAAA|BBB|CCC|DDD|EEE|FFF..
JAVA 엑셀파일 숫자 그대로 읽기 POI 라이브러리 사용 시 셀 서식이 숫지이고 숫자가 너무 크면 지수로 읽어진다 숫자인지 체크하고 셀 서식을 문자로 변경한 뒤 읽으면 된다public static String getCellValue(XSSFCell cell) { String value = null; switch(cell.getCellType()) { case XSSFCell.CELL_TYPE_FORMULA : value = cell.getCellFormula(); // 수식을 가져온다 break; case XSSFCell.CELL_TYPE_NUMERIC: cell.setCellType(HSSFCell.CELL_TYPE_STRING); value = cell.getStringCellValue(); bre..
unknown version of Tomcat was specified Problume 새로운 tomcat version을 설치하고 서버로 추가하려고 했는데 되지 않았다. Case 새로운 tomcat version을 설치하고 있는 중이다 Eclipse 하단에 Installing server runti...onment:라고 적혀있고 설치 %가 보이면 tomcat server를 설치 중인 것이다 Soulve 설치 완료 후 server 추가