Skip to content

Instantly share code, notes, and snippets.

View ivanursul's full-sized avatar

Ivan Ursul ivanursul

View GitHub Profile
/Users/ivanursul/development/Tools/apache-tomcat-8.0.24/bin/catalina.sh run
objc[4061]: Class JavaLaunchHelper is implemented in both /Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home/bin/java and /Library/Java/JavaVirtualMachines/jdk1.8.0.jdk/Contents/Home/jre/lib/libinstrument.dylib. One of the two will be used. Which one is undefined.
Connected to the target VM, address: '127.0.0.1:53079', transport: 'socket'
[2015-08-27 02:49:55,452] Artifact Gradle : iu-sport-ui : iu-sport-ui.war (exploded): Server is not connected. Deploy is not available.
[2015-08-27 02:49:55,453] Artifact Gradle : iu-sport:iu-sport-rest-api : iu-sport-rest-api.war (exploded): Server is not connected. Deploy is not available.
27-Aug-2015 14:49:56.873 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server version: Apache Tomcat/8.0.24
27-Aug-2015 14:49:56.876 INFO [main] org.apache.catalina.startup.VersionLoggerListener.log Server built: Jul 1 2015 20:19:55 UTC
27-Aug-2015 14:49:56.876 INFO [
<mvc:argument-resolvers>
<ref bean="pagedRequestHandlerMethodArgumentResolver" />
</mvc:argument-resolvers>
package org.lnu.is.web.rest.controller.asset;
import javax.annotation.Resource;
import org.lnu.is.facade.facade.Facade;
import org.lnu.is.facade.resource.asset.AssetResource;
import org.lnu.is.facade.resource.message.MessageResource;
import org.lnu.is.facade.resource.message.MessageType;
import org.lnu.is.facade.resource.search.PagedRequest;
import org.lnu.is.facade.resource.search.PagedResultResource;
package org.lnu.is.facade.resource.search;
import org.lnu.is.facade.annotations.Limit;
import org.lnu.is.facade.annotations.Offset;
/**
/**
* Paged Request, that comes from controller.
* @author ivanursul
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>google-guice</groupId>
<artifactId>google-guice</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>google-guice</name>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>google-guice</groupId>
<artifactId>google-guice</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>google-guice</name>
package org.ivanursul.guice.service;
public interface NotificationService {
boolean sendMessage(String msg, String receipient);
}
package org.ivanursul.guice.service;
import javax.inject.Singleton;
@Singleton
public class EmailService implements NotificationService {
public boolean sendMessage(final String msg, final String receipient) {
//some fancy code to send email
package org.ivanursul.guice.service;
import javax.inject.Singleton;
@Singleton
public class FacebookService implements NotificationService {
public boolean sendMessage(final String msg, final String receipient) {
//some complex code to send Facebook message