Created
August 5, 2017 00:34
-
-
Save gwokudasam/c40977df5165648127e1d7ad74216197 to your computer and use it in GitHub Desktop.
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 zw.co.poscloud.utilities; | |
import org.springframework.beans.factory.annotation.Value; | |
import org.springframework.stereotype.Component; | |
import java.net.URI; | |
/** | |
* @Author : gwokudasam | |
* @Date : 5/8/2017 | |
*/ | |
@Component | |
public class URIUtils{ | |
@Value("{server.port}") | |
private static Integer serverPort; | |
@Value("{server.address}") | |
private static Integer serverAddress; | |
public static URI createTeamURI(Integer id){ | |
return URI.create(String.format("http://%s:%d/teams", serverAddress, serverPort)); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment