You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@aries.apache.org by cs...@apache.org on 2017/08/18 14:01:56 UTC
[07/14] aries-jax-rs-whiteboard git commit: Can't have DefaultWeb now
Can't have DefaultWeb now
Project: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/repo
Commit: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/commit/f8f6baa1
Tree: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/tree/f8f6baa1
Diff: http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/diff/f8f6baa1
Branch: refs/heads/master
Commit: f8f6baa1535707fbd0bb895659378194d9e94525
Parents: 4760cd1
Author: Carlos Sierra <cs...@apache.org>
Authored: Mon Aug 14 14:19:40 2017 +0200
Committer: Carlos Sierra <cs...@apache.org>
Committed: Fri Aug 18 15:59:21 2017 +0200
----------------------------------------------------------------------
.../jax/rs/whiteboard/internal/DefaultWeb.java | 105 -------------------
1 file changed, 105 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/aries-jax-rs-whiteboard/blob/f8f6baa1/jax-rs.whiteboard/src/main/java/org/apache/aries/jax/rs/whiteboard/internal/DefaultWeb.java
----------------------------------------------------------------------
diff --git a/jax-rs.whiteboard/src/main/java/org/apache/aries/jax/rs/whiteboard/internal/DefaultWeb.java b/jax-rs.whiteboard/src/main/java/org/apache/aries/jax/rs/whiteboard/internal/DefaultWeb.java
deleted file mode 100644
index 711ee90..0000000
--- a/jax-rs.whiteboard/src/main/java/org/apache/aries/jax/rs/whiteboard/internal/DefaultWeb.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.aries.jax.rs.whiteboard.internal;
-
-import javax.ws.rs.GET;
-import javax.ws.rs.Path;
-import javax.ws.rs.Produces;
-import javax.ws.rs.core.CacheControl;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.Response;
-import javax.ws.rs.core.Response.ResponseBuilder;
-
-@Path("/")
-public class DefaultWeb {
-
- @GET
- @Produces(MediaType.TEXT_HTML)
- public Response home(){
- CacheControl cc = new CacheControl();
- cc.setMaxAge(86400);
- cc.setPrivate(true);
-
- ResponseBuilder builder = Response.ok(
- getClass().getResourceAsStream("/static/index.html"));
- builder.cacheControl(cc);
-
- return builder.build();
- }
-
- @GET
- @Path("/css")
- @Produces("text/css")
- public Response css() {
- CacheControl cc = new CacheControl();
- cc.setMaxAge(86400);
- cc.setPrivate(true);
-
- ResponseBuilder builder = Response.ok(
- getClass().getResourceAsStream("/static/style.css"));
- builder.cacheControl(cc);
-
- return builder.build();
- }
-
- @GET
- @Path("/github")
- @Produces("text/css")
- public Response github() {
- CacheControl cc = new CacheControl();
- cc.setMaxAge(86400);
- cc.setPrivate(true);
-
- ResponseBuilder builder = Response.ok(
- getClass().getResourceAsStream("/static/highlight/styles/github.css"));
- builder.cacheControl(cc);
-
- return builder.build();
- }
-
- @GET
- @Path("/highlight")
- @Produces("text/javascript")
- public Response highlight() {
- CacheControl cc = new CacheControl();
- cc.setMaxAge(86400);
- cc.setPrivate(true);
-
- ResponseBuilder builder = Response.ok(
- getClass().getResourceAsStream("/static/highlight/highlight.pack.js"));
- builder.cacheControl(cc);
-
- return builder.build();
- }
-
- @GET
- @Path("/logo")
- @Produces("image/gif")
- public Response logo() {
- CacheControl cc = new CacheControl();
- cc.setMaxAge(86400);
- cc.setPrivate(true);
-
- ResponseBuilder builder = Response.ok(
- getClass().getResourceAsStream("/static/Arieslogo_Horizontal.gif"));
- builder.cacheControl(cc);
-
- return builder.build();
- }
-
-}
\ No newline at end of file