일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- 초단위
- 엔티티 코드 치환
- 스프링 시큐리티
- Entity Code 치환
- Spring Security
- aws elasticache 활용
- js
- architecture
- 직렬화 오류
- 티스토리챌린지
- Java
- Linux
- javascript
- springboot+redis
- 제이쿼리
- docker 컨테이너로 띄우기
- 만들면서 배우는 클린 아키텍처
- 톰캣
- redis + spring boot 함께
- 자바스크립트
- 자바
- 오블완
- mysql
- 특수문자 치환
- Tomcat
- for문
- Docker Compose
- jQuery
- 리눅스
- 정규식
- Today
- Total
목록자바 (4)
꾸준하게, 차근차근

public static int timeToSec(String time) { String[] times = time.split(":"); int hours = Integer.parseInt(times[0]); int minutes = Integer.parseInt(times[1]); int seconds = Integer.parseInt(times[2]); int totalSeconds = (+hours) * 60 * 60 + (+minutes) * 60 + (+seconds); return totalSeconds; }

public static String secToTime(int time) { int hours = (int) Math.floor(times / 3600); int minutes = (int) Math.floor((times - (hours * 3600)) / 60); int seconds = (int) Math.floor((times - (hours * 3600) - (minutes * 60))); String hoursStr = String.valueOf(hours); String minutesStr = String.valueOf(minutes); String secondsStr = String.valueOf(seconds); if (hours < 10) {hoursStr = "0" + hours;} ..

1. emoji-java maven 설정 추가 참고사항: 문자열에 이모티콘이 포함되어 있는지 확인하는 메소드는 5.대 버전에서 제공하는 것 같다. 4.대 버전에서는 해당 메소드가 존재하지 않았다. com.vdurmont emoji-java 5.1.1 해당 클래스에서 제공하는 메소드를 몇 개만 간략하게 정리하겠다. 2. EmojiManager 메소드 종류 getForTag : 주어진 태그에 대한 모든 이모티콘 반환 getForAlias : 별칭에 대한 이모티콘 반환 getAll : 모든 이모티콘 반환 isEmoji : 문자열이 이모티콘인지 확인 containsEmoji : 문자열에 이모티콘이 포함되어 있는지 확인 3. EmojiParser 메소드 종류 parseToUnicode(String) : 모든 별칭..

import org.apache.commons.lang3.StringEscapeUtils; public void changeHtml() { // 특수문자를 Entity Code로 치환 String str = "&&&&"; str = StringEscapeUtils.escapeHtml4(str); // Entity Code를 특수문자로 치환 String entityStr = "&&&&"; entityStr = StringEscapeUtils.unescapeHtml4(entityStr); } 🙏 참조 :: https://kudolove.tistory.com/m/1350 https://commons.apache.org/proper/commons-lang/apidocs/org/apache/commons/lang..