This file contains 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 * as express from 'express'; | |
import {injectable, inject} from 'inversify'; | |
import TYPES from '../types'; | |
import {AddressService} from '../service/AddressService'; | |
import {Address} from '../model/Address'; | |
import {RegistrableController} from './RegisterableController'; | |
@injectable() | |
export class AddressController implements RegistrableController { | |
private addressService: AddressService; |
This file contains 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 Application { | |
public static final String SPRING_PROFILES_ACTIVE = "lego.profiles.active"; | |
public static final String DEFAULT_PROFILE = "local"; | |
public static void main(String[] args) throws Exception { | |
SimpleCommandLinePropertySource source = new SimpleCommandLinePropertySource(args); | |
String profile = Optional.ofNullable(source.getProperty(SPRING_PROFILES_ACTIVE)).orElse(DEFAULT_PROFILE); |