Advertisement
Guest User

Untitled

a guest
May 29th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.53 KB | None | 0 0
  1. @Module(subcomponents = ChatComponent.class)
  2. public class ChatModule {
  3.  
  4.     @Named("chat-id") private final long chatId;
  5.     @Named("channel-token") private final String channelToken;
  6.  
  7.     public ChatModule(long chatId, String channelToken) {
  8.         this.chatId = chatId;
  9.         this.channelToken = channelToken;
  10.     }
  11.  
  12.     @Provides
  13.     @Named("chat-id") long provideChannelId() {
  14.         return chatId;
  15.     }
  16.  
  17.     @Provides
  18.     @Named("channel-token") String provideChannelToken() {
  19.         return channelToken;
  20.     }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement