-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
new types for relative uris and relative graphs #41
Comments
Here would be another example where this would help understanding. In trait LDPS[Rdf <: RDF] {
def baseUri: Rdf#URI
def shutdown(): Unit
def createLDPC(uri: Rdf#rURI): Future[LDPC[Rdf]]
def getLDPC(uri: Rdf#rURI): Future[LDPC[Rdf]]
def deleteLDPC(uri: Rdf#rURI): Future[Unit]
} This makes the |
@bblfish I was thinking about using scalaz Tags for that. Would it be ok for you? |
If your solution makes it easy to distinguish relative and absolute urls that's what's needed. Short term it will take a lot of reworking of code, but long term it will remove ugly errors. ( I am not sure about scalaz Tags, I'll have to look. ) I'll be back on writing Scala RWW-Play from tomorrow, as I have to provide an LDP platform for a number of French universities in the next month or two. |
A use case for relative URL support and relative graph support: The server may not know its own name read-write-web/rww-play#152 |
Perhaps it would be useful to create types for relative URIs and relative graphs.
type URI <: rURI
Then one could have two types of graphs Graph[URI] and Graph[rURI] == rGraph where the type specifies the upper limit for the URI. All else would remain the same.
This would just help make it clearer what could be done with the different graphs. For serialisation an rGraph would be fine. For reasoning only Graphs would be useable. Then there are interesting cases where one may
case class LDPR(uri: URI, graph: rGraph)
or perhaps
case class LDPR(uri: rURI, graph rGraph, container: LDPC)
where the container fills in the rest of the URI?
The text was updated successfully, but these errors were encountered: