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
| #!/usr/bin/env bash | |
| ### BEGIN INIT INFO | |
| # Provides: Shadowsocks-libev | |
| # Required-Start: $network $local_fs $remote_fs | |
| # Required-Stop: $network $local_fs $remote_fs | |
| # Default-Start: 2 3 4 5 | |
| # Default-Stop: 0 1 6 | |
| # Short-Description: Fast tunnel proxy that helps you bypass firewalls | |
| # Description: Start or stop the Shadowsocks-libev server |
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.luv2code.springdemo.mvc.validation; | |
| import java.lang.annotation.ElementType; | |
| import java.lang.annotation.Retention; | |
| import java.lang.annotation.RetentionPolicy; | |
| import java.lang.annotation.Target; | |
| import javax.validation.Constraint; | |
| import javax.validation.Payload; |
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
| @Configuration | |
| public class SnakeCaseApplicationConfiguration { | |
| @Bean | |
| public OncePerRequestFilter snakeCaseConverterFilter() { | |
| return new OncePerRequestFilter() { | |
| @Override | |
| protected void doFilterInternal(HttpServletRequest request, HttpServletResponse response, FilterChain filterChain) throws ServletException, IOException { | |
| final Map<String, String[]> parameters = new ConcurrentHashMap<>(); | |
| for (String param : request.getParameterMap().keySet()) { |
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 xxx.xxx.xxx.StringUtil; | |
| import org.springframework.core.annotation.Order; | |
| import org.springframework.lang.NonNull; | |
| import org.springframework.stereotype.Component; | |
| import org.springframework.util.ObjectUtils; | |
| import org.springframework.web.filter.OncePerRequestFilter; | |
| import javax.servlet.FilterChain; | |
| import javax.servlet.ServletException; |
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
| public class CodeGenerator { | |
| private static final String PROJECT_PATH = System.getProperty("user.dir"); | |
| private static final String AUTHOR = "xxx"; | |
| private static final String DB_URL = "xxx"; | |
| private static final String DB_DRIVER_NAME = "org.postgresql.Driver"; | |
| private static final String DB_USERNAME = "xxx"; | |
| private static final String DB_PASSWORD = "xxx"; | |
| private static final String PARENT_PACKAGE = "com.example.demo"; | |
| private static final String[] EXCLUDE_TABLES = List.of("flyway_schema_history").toArray(new String[0]); | |
| private static final Boolean FILE_OVERRIDE = true; |
OlderNewer