This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.przemekpretki; | |
| import org.apache.lucene.analysis.miscellaneous.ASCIIFoldingFilter; | |
| public class Main { | |
| static String toASCII(String text) { | |
| char[] output = new char[4 * text.length()]; | |
| ASCIIFoldingFilter.foldToASCII(text.toCharArray(), 0, output, 0, text.length()); | |
| return new String(output).trim(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import static spark.Spark.*; | |
| import javax.json.Json; | |
| import lombok.extern.slf4j.Slf4j; | |
| @Slf4j | |
| public class VerneMQWebHooks { | |
| private static final String RESULT_OK = Json.createObjectBuilder() | |
| .add("result", "ok") |