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
SELECT ID, NAME | |
XMLTYPE(u.accountxml).EXTRACT('/person/account/sortCode/text()') as SORTCODE | |
FROM USER u; |
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
package com.cor; | |
import org.springframework.boot.SpringApplication; | |
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; | |
import org.springframework.context.annotation.ComponentScan; | |
/** | |
* Spring Boot launch file. | |
*/ | |
@ComponentScan |
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
package com.cor.controller; | |
import static org.springframework.hateoas.mvc.ControllerLinkBuilder.linkTo; | |
import static org.springframework.hateoas.mvc.ControllerLinkBuilder.methodOn; | |
import java.util.ArrayList; | |
import java.util.Collection; | |
import java.util.List; | |
import org.springframework.beans.factory.annotation.Autowired; | |
import org.springframework.hateoas.Resource; | |
import org.springframework.http.MediaType; |
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
package com.cor.controller; | |
import static org.springframework.hateoas.mvc.ControllerLinkBuilder.linkTo; | |
import static org.springframework.hateoas.mvc.ControllerLinkBuilder.methodOn; | |
import org.springframework.beans.factory.annotation.Autowired; | |
import org.springframework.hateoas.Resource; | |
import org.springframework.http.MediaType; | |
import org.springframework.stereotype.Controller; | |
import org.springframework.web.bind.annotation.PathVariable; | |
import org.springframework.web.bind.annotation.RequestMapping; |
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
package com.cor.domain; | |
/** | |
* Album (available to purchase - hence 'stockLevel' attribute). | |
* | |
*/ | |
public class Album { | |
private final String id; | |
private final String title; |
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
package com.cor.domain; | |
/** | |
* Music Artist/Group. | |
* | |
*/ | |
public class Artist { | |
private final String id; | |
private final String name; |
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
package com.cor.service; | |
import java.util.Collection; | |
import java.util.HashMap; | |
import java.util.Map; | |
import org.springframework.stereotype.Service; | |
import com.cor.domain.Album; | |
import com.cor.domain.Artist; | |
/** |
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
<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>com.cor</groupId> | |
<artifactId>spring-hateoas-demo</artifactId> | |
<version>0.0.1-SNAPSHOT</version> | |
<name>spring-hateoas-demo</name> | |
<parent> | |
<groupId>org.springframework.boot</groupId> | |
<artifactId>spring-boot-starter-parent</artifactId> |
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
broker.url=tcp://localhost:61616 | |
broker.queue=corsoft.BroadcastMessageQueue | |
cometd.channel=cometd://0.0.0.0:9099/broadcastMessageChannel |
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
google.load("jquery", "1"); | |
/** | |
* Callback function - Cometd consumer. | |
*/ | |
google.setOnLoadCallback(function() { | |
$.getScript("http://jquerycomet.googlecode.com/svn/trunk/jquery.comet.js", function(){ | |
console.log("done loading js"); | |
$.comet.init("http://localhost:9099/cometd"); | |
$.comet.subscribe("/broadcastMessageChannel", broadcastListener); |
OlderNewer