Проблема с классом StorageProperties на spring.io/guides/uploading-file - PullRequest
0 голосов
/ 20 июня 2019

Я изучаю веб-сервис RESTful в spring.io/uploadfile, но у меня возникает проблема при импорте StorageProperties:

Я не знаю, что это такое и как его использовать.это приложение Java:

  import org.springframework.boot.CommandLineRunner;
    import org.springframework.boot.SpringApplication;
    import org.springframework.boot.autoconfigure.SpringBootApplication;
    import org.springframework.boot.context.properties.EnableConfigurationProperties;
    import org.springframework.context.annotation.Bean;

    import com.java.StorageProperties;
    import com.java.StorageService;

    @SpringBootApplication
    @EnableConfigurationProperties(StorageProperties.class) 
    public class Application {

        public static void main(String[] args) {
            SpringApplication.run(Application.class, args);
        }

        @Bean
        CommandLineRunner init(StorageService storageService) {
            return (args) -> {
                storageService.deleteAll();
                storageService.init();
            };
        }
    }

Импорт com.java.StorageProperties не может быть разрешен, но я не видел ни одного класса, подобного StorageProperties в этом проекте.

...