Author: chathura
Date: Wed Jan  9 21:57:34 2008
New Revision: 12092

Log:


Adding xsd support...



Added:
   
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/XSDMediaTypeHandler.java
   
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/utils/PropertiesUtil.java
   
trunk/registry/modules/webapps/src/main/webapp/admin/ajax/resource-properties.jsp
Modified:
   
trunk/registry/modules/core/src/main/java/org/wso2/registry/RegistryConstants.java
   
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/MediaTypeManager.java
   
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/WSDLMediaTypeHandler.java
   
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/SchemaFileProcessor.java
   
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/WSDLFileProcessor.java
   trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp

Modified: 
trunk/registry/modules/core/src/main/java/org/wso2/registry/RegistryConstants.java
==============================================================================
--- 
trunk/registry/modules/core/src/main/java/org/wso2/registry/RegistryConstants.java
  (original)
+++ 
trunk/registry/modules/core/src/main/java/org/wso2/registry/RegistryConstants.java
  Wed Jan  9 21:57:34 2008
@@ -88,6 +88,7 @@
     // built in media types
 
     public static final String WSDL_MEDIA_TYPE = "application/wsdl+xml";
+    public static final String XSD_MEDIA_TYPE = "application/x-xsd+xml";
     public static final String SYNPASE_REPOSITORY_MEDIA_TYPE = "synapse-repo";
     public static final String SYNAPSE_CONF_COLLECTION_MEDIA_TYPE = 
"synapse-conf";
     public static final String SYNAPSE_SEQUENCE_COLLECTION_MEDIA_TYPE = 
"synapse-sequences";

Modified: 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/MediaTypeManager.java
==============================================================================
--- 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/MediaTypeManager.java
   (original)
+++ 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/MediaTypeManager.java
   Wed Jan  9 21:57:34 2008
@@ -25,10 +25,7 @@
 import org.wso2.registry.i18n.Messages;
 import org.wso2.registry.jdbc.JDBCRegistry;
 import org.wso2.registry.jdbc.dao.VersionedResourceDAO;
-import org.wso2.registry.jdbc.mediatypes.builtin.DefaultMediaTypeHandler;
-import org.wso2.registry.jdbc.mediatypes.builtin.SQLQueryMediaTypeHandler;
-import 
org.wso2.registry.jdbc.mediatypes.builtin.SynapseRepositoryMediaTypeHandler;
-import org.wso2.registry.jdbc.mediatypes.builtin.WSDLMediaTypeHandler;
+import org.wso2.registry.jdbc.mediatypes.builtin.*;
 import org.wso2.usermanager.Realm;
 
 import javax.sql.DataSource;
@@ -73,6 +70,9 @@
         MediaTypeHandler wsdlMediaTypeHandler =
                 new WSDLMediaTypeHandler(dataSource, realm, this);
         mediaTypeHandlers.put(RegistryConstants.WSDL_MEDIA_TYPE, 
wsdlMediaTypeHandler);
+
+        MediaTypeHandler xsdMediaTypeHandler = new 
XSDMediaTypeHandler(dataSource, realm, this);
+        mediaTypeHandlers.put(RegistryConstants.XSD_MEDIA_TYPE, 
xsdMediaTypeHandler);
     }
 
     public Resource get(String path) throws RegistryException {

Modified: 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/WSDLMediaTypeHandler.java
==============================================================================
--- 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/WSDLMediaTypeHandler.java
       (original)
+++ 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/WSDLMediaTypeHandler.java
       Wed Jan  9 21:57:34 2008
@@ -60,7 +60,7 @@
         return false;
     }
 
-    private static String getParentPath(String childPath) {
+    private String getParentPath(String childPath) {
 
         if (childPath.equals(RegistryConstants.ROOT_PATH)) {
             return null;

Added: 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/XSDMediaTypeHandler.java
==============================================================================
--- (empty file)
+++ 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/XSDMediaTypeHandler.java
        Wed Jan  9 21:57:34 2008
@@ -0,0 +1,77 @@
+/*
+ * Copyright (c) 2006, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+ *
+ * Licensed 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.wso2.registry.jdbc.mediatypes.builtin;
+
+import org.wso2.registry.jdbc.mediatypes.MediaTypeHandler;
+import org.wso2.registry.jdbc.mediatypes.MediaTypeManager;
+import org.wso2.registry.jdbc.mediatypes.builtin.utils.SchemaFileProcessor;
+import org.wso2.registry.Resource;
+import org.wso2.registry.RegistryException;
+import org.wso2.registry.RegistryConstants;
+import org.wso2.usermanager.Realm;
+
+import javax.sql.DataSource;
+
+public class XSDMediaTypeHandler extends MediaTypeHandler {
+
+    SchemaFileProcessor schemaFileProcessor;
+
+    public XSDMediaTypeHandler(DataSource dataSource,
+                                Realm realm,
+                                MediaTypeManager mediaTypeManager) {
+
+        super(dataSource, realm, mediaTypeManager);
+
+        schemaFileProcessor = new 
SchemaFileProcessor(mediaTypeManager.getDefaultMediaTypeHandler());
+
+    }
+
+    public Resource get(String path, Resource rawArtifact) throws 
RegistryException {
+        return null;
+    }
+
+    public boolean put(String path, Resource resource) throws 
RegistryException {
+        String xsdURL = resource.getProperty("fetchURL");
+        schemaFileProcessor.saveSchemaFileToRegistry(xsdURL, 
getParentPath(path));
+
+        return true;
+    }
+
+    public boolean delete(String path) throws RegistryException {
+        return false;
+    }
+
+    public boolean putChild(String childPath, Resource resource) throws 
RegistryException {
+        return false;
+    }
+
+    private String getParentPath(String childPath) {
+
+        if (childPath.equals(RegistryConstants.ROOT_PATH)) {
+            return null;
+        }
+
+        int parentPathLength = 
childPath.lastIndexOf(RegistryConstants.PATH_SEPARATOR);
+
+        if (parentPathLength == 0) {
+            return RegistryConstants.ROOT_PATH;
+        }
+
+        String parentPath = childPath.substring(0, parentPathLength);
+        return parentPath;
+    }
+}

Modified: 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/SchemaFileProcessor.java
==============================================================================
--- 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/SchemaFileProcessor.java
  (original)
+++ 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/SchemaFileProcessor.java
  Wed Jan  9 21:57:34 2008
@@ -21,17 +21,28 @@
 import org.apache.ws.commons.schema.XmlSchemaExternal;
 import org.apache.ws.commons.schema.XmlSchemaObjectCollection;
 import org.xml.sax.InputSource;
+import org.wso2.registry.jdbc.mediatypes.builtin.DefaultMediaTypeHandler;
+import org.wso2.registry.Resource;
+import org.wso2.registry.RegistryConstants;
+import org.wso2.registry.RegistryException;
 
 import javax.xml.transform.OutputKeys;
 import java.io.FileNotFoundException;
 import java.io.FileOutputStream;
+import java.io.ByteArrayOutputStream;
 import java.util.*;
 
 public class SchemaFileProcessor {
 
+    private DefaultMediaTypeHandler defaultMediaTypeHandler;
+
     // remove this when it is not needed
     private int i;
 
+    public SchemaFileProcessor(DefaultMediaTypeHandler 
defaultMediaTypeHandler) {
+        this.defaultMediaTypeHandler = defaultMediaTypeHandler;
+    }
+
     /**
      * saves the file to the reginstry after saving all its inclues and 
imports to the reginstry and
      * updating the schema locations accordingly.
@@ -40,10 +51,10 @@
      * @throws FileNotFoundException
      */
 
-    public void saveSchemaFileToRegistry(String location)
-            throws FileNotFoundException {
+    public void saveSchemaFileToRegistry(String location, String 
registryBasePath)
+            throws RegistryException {
 
-        saveSchemaFileToRegistry(location, new HashMap());
+        saveSchemaFileToRegistry(location, new HashMap(), registryBasePath);
     }
 
     /**
@@ -51,7 +62,9 @@
      * @param processedSchemaMap - this map contains schema source URI vs new 
schema locaitons.
      */
     public void saveSchemaFileToRegistry(String location,
-                                         Map processedSchemaMap) {
+                                         Map processedSchemaMap, String 
registryBasePath)
+            throws RegistryException {
+
         XmlSchemaCollection xmlSchemaCollection = new XmlSchemaCollection();
         InputSource inputSource = new InputSource(location);
         // here we assue schema is correct. schema validation is beyond 
registry scope.
@@ -59,7 +72,7 @@
         XmlSchema xmlSchema = xmlSchemaCollection.read(inputSource, null);
         // this is not an inline wsdl schema. so pass null to change map.
         calculateNewSchemaNames(xmlSchema, processedSchemaMap, new HashSet(), 
false);
-        saveSchemaFileToRegistry(xmlSchema, processedSchemaMap, null, new 
HashSet(), false);
+        saveSchemaFileToRegistry(xmlSchema, processedSchemaMap, null, new 
HashSet(), false, registryBasePath);
     }
 
     /**
@@ -97,9 +110,9 @@
                     // we do not need to process it if it already process
                     // when calling with a different import.
                     if 
(!processedSchemaMap.containsKey(innerSchema.getSourceURI()) &&
-                        !visitedShemas.contains(innerSchema.getSourceURI())) {
+                            
!visitedShemas.contains(innerSchema.getSourceURI())) {
                         calculateNewSchemaNames(xmlSchemaExternal.getSchema(),
-                                                processedSchemaMap, 
visitedShemas, false);
+                                processedSchemaMap, visitedShemas, false);
                     }
                 }
             }
@@ -134,7 +147,8 @@
                                          Map processedSchemaMap,
                                          Map changeSchemaNames,
                                          Set visitedShemas,
-                                         boolean isWsdlInlineSchema) {
+                                         boolean isWsdlInlineSchema,
+                                         String registryBasePath) throws 
RegistryException {
 
         // first process the imports and includes
         XmlSchemaObjectCollection includes = xmlSchema.getIncludes();
@@ -151,15 +165,15 @@
                     innerSchema = xmlSchemaExternal.getSchema();
                     if (!visitedShemas.contains(innerSchema.getSourceURI())) {
                         saveSchemaFileToRegistry(xmlSchemaExternal.getSchema(),
-                                                 processedSchemaMap, null, 
visitedShemas, false);
+                                processedSchemaMap, null, visitedShemas, 
false, registryBasePath);
                     }
 
                     // add the new name to changeschema map
                     // have to do before change the schema location
                     if (isWsdlInlineSchema) {
                         
changeSchemaNames.put(xmlSchemaExternal.getSchemaLocation(),
-                                              (String)processedSchemaMap.get(
-                                                      
innerSchema.getSourceURI()));
+                                (String)processedSchemaMap.get(
+                                        innerSchema.getSourceURI()));
                     }
                     // set the new location
                     
xmlSchemaExternal.setSchemaLocation((String)processedSchemaMap.get(
@@ -172,13 +186,17 @@
         // after processing includes and imports save the xml schema
         if (!isWsdlInlineSchema) {
             String fileNameToSave = 
(String)processedSchemaMap.get(xmlSchema.getSourceURI());
-            try {
-                xmlSchema.write(new FileOutputStream("repository/" + 
fileNameToSave),
-                                getDefaultOptionMap());
-                // add this entry to the proccessed wsdl map
-            } catch (FileNotFoundException e) {
-                e.printStackTrace();
-            }
+            ByteArrayOutputStream byteArrayOutputStream = new 
ByteArrayOutputStream();
+            xmlSchema.write(byteArrayOutputStream);
+            byte[] xsdContent = byteArrayOutputStream.toByteArray();
+
+            Resource xsdResource = new Resource();
+            xsdResource.setContent(xsdContent);
+            defaultMediaTypeHandler.put(registryBasePath + 
RegistryConstants.PATH_SEPARATOR + fileNameToSave, xsdResource);
+
+            //xmlSchema.write(new FileOutputStream("repository/" + 
fileNameToSave),
+            //                getDefaultOptionMap());
+            // add this entry to the proccessed wsdl map
         }
     }
 

Modified: 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/WSDLFileProcessor.java
==============================================================================
--- 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/WSDLFileProcessor.java
    (original)
+++ 
trunk/registry/modules/core/src/main/java/org/wso2/registry/jdbc/mediatypes/builtin/utils/WSDLFileProcessor.java
    Wed Jan  9 21:57:34 2008
@@ -82,7 +82,7 @@
 
         Map processedWSDLMap = new HashMap();
         calculateWSDLNamesAndChangeTypes(wsdlDefinition, processedWSDLMap, new 
HashMap(),
-                                         new HashSet());
+                                         new HashSet(), registryBasePath);
         saveWSDLFileToRegistry(wsdlDefinition, processedWSDLMap, new 
HashSet(), registryBasePath);
     }
 
@@ -98,7 +98,8 @@
     public void calculateWSDLNamesAndChangeTypes(Definition wsdlDefinition,
                                                  Map processedWSDLMap,
                                                  Map processedScheamMap,
-                                                 Set visitedWSDLs) {
+                                                 Set visitedWSDLs,
+                                                 String registryBasePath) 
throws RegistryException {
         // first we have to process the imports and change the
         // schema locations suite for the registry
         Iterator iter = wsdlDefinition.getImports().values().iterator();
@@ -115,7 +116,7 @@
                 if 
(!visitedWSDLs.contains(innerDefinition.getDocumentBaseURI())) {
                     // we have not process this wsdl file earlier
                     calculateWSDLNamesAndChangeTypes(
-                            innerDefinition, processedWSDLMap, 
processedScheamMap, visitedWSDLs);
+                            innerDefinition, processedWSDLMap, 
processedScheamMap, visitedWSDLs, registryBasePath);
                 }
             }
         }
@@ -142,12 +143,12 @@
                     xmlSchemaCollection = new XmlSchemaCollection();
                     xmlSchemaCollection.setBaseUri(basuri);
                     xmlSchema = 
xmlSchemaCollection.read(schemaExtension.getElement());
-                    schemaFileProcessor = new SchemaFileProcessor();
+                    schemaFileProcessor = new 
SchemaFileProcessor(defaultMediaTypeHandler);
                     changedLocationMap = new HashMap();
                     schemaFileProcessor.calculateNewSchemaNames(
                             xmlSchema, processedScheamMap, new HashSet(), 
true);
                     schemaFileProcessor.saveSchemaFileToRegistry(
-                            xmlSchema, processedScheamMap, changedLocationMap, 
new HashSet(), true);
+                            xmlSchema, processedScheamMap, changedLocationMap, 
new HashSet(), true, registryBasePath);
                     // update the current schema locations with the generated 
ones.
                     changeLocations(schemaExtension.getElement(), 
changedLocationMap);
                 }

Added: 
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/utils/PropertiesUtil.java
==============================================================================
--- (empty file)
+++ 
trunk/registry/modules/webapps/src/main/java/org/wso2/registry/web/utils/PropertiesUtil.java
        Wed Jan  9 21:57:34 2008
@@ -0,0 +1,56 @@
+/*
+ * Copyright (c) 2006, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+ *
+ * Licensed 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.wso2.registry.web.utils;
+
+import org.wso2.registry.secure.SecureRegistry;
+import org.wso2.registry.RegistryException;
+import org.wso2.registry.Resource;
+
+import javax.servlet.http.HttpServletRequest;
+import java.util.Properties;
+
+public class PropertiesUtil {
+
+    public static Properties getResourceProperties(String resourcePath, 
HttpServletRequest request)
+            throws RegistryException {
+
+        SecureRegistry secureRegistry = CommonUtil.getUserRegistry(request);
+        Resource resource = secureRegistry.get(resourcePath);
+
+        return resource.getProperties();
+    }
+
+    public static void setProperty(
+            String resourcePath,
+            String propertyName,
+            String propertyValue,
+            HttpServletRequest request) throws RegistryException {
+
+        SecureRegistry secureRegistry = CommonUtil.getUserRegistry(request);
+        Resource resource = secureRegistry.get(resourcePath);
+
+        resource.setProperty(propertyName, propertyValue);
+    }
+
+    public static void removeProperty(String resourcePath, String 
propertyName, HttpServletRequest request) throws RegistryException {
+
+        SecureRegistry secureRegistry = CommonUtil.getUserRegistry(request);
+        Resource resource = secureRegistry.get(resourcePath);
+
+        resource.getProperties().remove(propertyName);
+    }
+}

Added: 
trunk/registry/modules/webapps/src/main/webapp/admin/ajax/resource-properties.jsp
==============================================================================
--- (empty file)
+++ 
trunk/registry/modules/webapps/src/main/webapp/admin/ajax/resource-properties.jsp
   Wed Jan  9 21:57:34 2008
@@ -0,0 +1,28 @@
+<%@ page import="java.util.Properties" %>
+<%@ page import="org.wso2.registry.web.utils.PropertiesUtil" %>
+<%@ page import="java.util.Iterator" %>
+<%--
+  Created by IntelliJ IDEA.
+  User: chathura
+  Date: Jan 9, 2008
+  Time: 3:41:26 PM
+  To change this template use File | Settings | File Templates.
+--%>
+<%@ page contentType="text/html;charset=UTF-8" language="java" %>
+<h2>Properties</h2>
+
+<%
+    String resourcePath = request.getParameter("resourcePath");
+    Properties props = PropertiesUtil.getResourceProperties(resourcePath, 
request);
+
+    Iterator iProps = props.keySet().iterator();
+    while (iProps.hasNext()) {
+
+        String name = (String) iProps.next();
+        String value = (String) props.get(name);
+
+        %>
+        <strong><%=name%></strong>: <%=value%>
+        <%
+    }
+%>

Modified: 
trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp
==============================================================================
--- trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp 
(original)
+++ trunk/registry/modules/webapps/src/main/webapp/admin/registry-resources.jsp 
Wed Jan  9 21:57:34 2008
@@ -3,12 +3,10 @@
 <%@ page import="java.util.Iterator" %>
 <%@ page import="org.wso2.registry.web.actions.utils.ResourceData" %>
 <%@ page import="org.wso2.registry.web.UIConstants" %>
-<%@ page import="org.wso2.registry.web.actions.utils.VersionPath" %>
 <%@ page import="org.wso2.registry.Tag" %>
 <%@ page import="org.wso2.registry.Comment" %>
 <%@ page import="org.wso2.registry.web.actions.utils.ResourcePath" %>
 <%@ page import="java.util.List" %>
-<%@ page import="org.wso2.registry.RegistryConstants" %>
 <%@ page contentType="text/html;charset=UTF-8" language="java" %>
 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
 "http://www.w3.org/TR/html4/strict.dtd";>
@@ -88,7 +86,7 @@
             } %>
         </h1>
         <!-- a href="#" style="float:right; 
display:inline;margin-top:10px;margin-right:5px;"><img 
src="/wso2registry/admin/images/icon-folder-up.jpg" border="0" / --></a>
-        <span style="clear:both;" />
+    <span style="clear:both;" />
 </div>
 <table cellspacing="0" cellpadding="0" border="0" style="width:100%">
 <tr>
@@ -123,37 +121,39 @@
         <tr><th>Versions</th><td colspan="3"><a 
href="/wso2registry/versions<%=details.getPath()%>">View versions</a></td> </tr>
     </table>
     <div id="ratingDiv"><img src="/wso2registry/admin/images/ajax-loader.gif" 
/></div>
-    
+
     <!-- Description editing will goes here -->
     <script type="text/javascript" xml:space="preserve">
         new Ajax.Updater('ratingDiv', '/wso2registry/system/getInitialRating', 
{ method: 'get', parameters: {resourcePath: '<%=details.getPath()%>'} });
     </script>
-    
-    
-    
+
+    <div id="resourceProperties"></div>
+    <script type="text/javascript" xml:space="preserve">
+        new Ajax.Updater('resourceProperties', 
'/wso2registry/system/getResourceProperties', { method: 'get', parameters: 
{resourcePath: '<%=details.getPath()%>'} });
+    </script>
 
     <table cellpadding="0" cellspacing="0" border="0" 
class="simple-data-table" style="width:100%">
         <tr>
-               <th style="width:120px; padding-bottom:10px; " 
valign="top">Description:</th>
-               <td valign="top" style="width:17px;">
-               <% if (details.isPutAllowed()) { %>
-                       <a href="#editButton" id="editButton" name="editButton" 
title="Edit Description" onclick="processDescription();"><img 
src="/wso2registry/admin/images/icon-edit.gif" name="editButtonImage" 
border="0" align="top" id="mainIconExpanded" /></a>
-               <% } %>
-               </td>
-               
-               <td valign="top">
-                       <div id="descView" style="display:block;">
-                               description...
-                       </div>
-                       
-                       <textarea class="resource-content" id="descEdit" 
style="display:none;">
-                       description...
-                       </textarea>
-               
-               </td>
+            <th style="width:120px; padding-bottom:10px; " 
valign="top">Description:</th>
+            <td valign="top" style="width:17px;">
+                <% if (details.isPutAllowed()) { %>
+                <a href="#editButton" id="editButton" name="editButton" 
title="Edit Description" onclick="processDescription();"><img 
src="/wso2registry/admin/images/icon-edit.gif" name="editButtonImage" 
border="0" align="top" id="mainIconExpanded" /></a>
+                <% } %>
+            </td>
+
+            <td valign="top">
+                <div id="descView" style="display:block;">
+                    description...
+                </div>
+
+                <textarea class="resource-content" id="descEdit" 
style="display:none;">
+                    description...
+                </textarea>
+
+            </td>
         </tr>
     </table>
-    
+
 
     <script type="text/javascript" xml:space="preserve">
         new Ajax.Updater('descView', '/wso2registry/system/getDescription', { 
method: 'get', parameters: {resourcePath: '<%=details.getPath()%>'} });
@@ -161,7 +161,7 @@
     </script>
 
 
-    
+
 
 
     <!-- End box1-mid div -->
@@ -421,8 +421,8 @@
 
 </td>
 <td style="padding-left:10px;" valign="top">
-<!-- Tag cloude box starts here -->
-<!-- Hear comes the box2 table -->
+    <!-- Tag cloude box starts here -->
+    <!-- Hear comes the box2 table -->
 <div class="box2-head">
     <table cellspacing="0" cellpadding="0" border="0" style="width:100%">
         <tr>
@@ -463,7 +463,9 @@
         </tr>
         <tr>
             <td style="font-style:italic;">
+
                 <img src="/wso2registry/admin/images/help-small.jpg" 
style="margin-right:5px;" />Use commas ("one, two") to add multiple tags.
+
             </td>
         </tr>
     </table>
@@ -554,52 +556,52 @@
 <!-- Version box starts -->
 <!-- Hear comes the box2 table -->
 <%--<div class="box2-head">--%>
-    <%--<table cellspacing="0" cellpadding="0" border="0" 
style="width:100%">--%>
-        <%--<tr>--%>
-            <%--<td valign="top" style="padding-top:0px;width:14px;"><img 
src="/wso2registry/admin/images/box2-lefttop.jpg" /></td>--%>
-            <%--<td valign="top"><h2>Versions</h2></td>--%>
-            <%--<td align="right" valign="top">--%>
-                <%--<a href="#" 
onclick="showHideCommon('versionsIconExpanded');showHideCommon('versionsIconMinimized');showHideCommon('versionsExpanded');showHideCommon('versionsMinimized');">--%>
-                    <%--<img 
src="/wso2registry/admin/images/icon-expanded.gif" border="0" align="top" 
id="versionsIconExpanded" style="display:none;" />--%>
-                    <%--<img 
src="/wso2registry/admin/images/icon-minimized.gif" border="0" align="top" 
id="versionsIconMinimized" />--%>
-                <%--</a>--%>
-            <%--</td>--%>
-            <%--<td valign="top" align="right" style="width:14px; 
padding-top:0px;" ><img src="/wso2registry/admin/images/box2-righttop.jpg" 
/></td>--%>
-        <%--</tr>--%>
-    <%--</table>--%>
+<%--<table cellspacing="0" cellpadding="0" border="0" style="width:100%">--%>
+<%--<tr>--%>
+<%--<td valign="top" style="padding-top:0px;width:14px;"><img 
src="/wso2registry/admin/images/box2-lefttop.jpg" /></td>--%>
+<%--<td valign="top"><h2>Versions</h2></td>--%>
+<%--<td align="right" valign="top">--%>
+<%--<a href="#" 
onclick="showHideCommon('versionsIconExpanded');showHideCommon('versionsIconMinimized');showHideCommon('versionsExpanded');showHideCommon('versionsMinimized');">--%>
+<%--<img src="/wso2registry/admin/images/icon-expanded.gif" border="0" 
align="top" id="versionsIconExpanded" style="display:none;" />--%>
+<%--<img src="/wso2registry/admin/images/icon-minimized.gif" border="0" 
align="top" id="versionsIconMinimized" />--%>
+<%--</a>--%>
+<%--</td>--%>
+<%--<td valign="top" align="right" style="width:14px; padding-top:0px;" ><img 
src="/wso2registry/admin/images/box2-righttop.jpg" /></td>--%>
+<%--</tr>--%>
+<%--</table>--%>
 <%--</div>--%>
 <%--<div class="box2-mid" id="versionsMinimized">--%>
-    <%--<a href="/wso2registry/versions<%=details.getPath()%>">View 
versions</a>--%>
+<%--<a href="/wso2registry/versions<%=details.getPath()%>">View 
versions</a>--%>
 <%--</div>--%>
 <%--<div class="box2-mid" id="versionsExpanded" style="display:none;">--%>
 
-    <%--<%--%>
-        <%--Iterator iVersions = details.getVersionPaths().iterator();--%>
-        <%--while (iVersions.hasNext()) {--%>
-            <%--VersionPath versionPath = (VersionPath) iVersions.next();--%>
-    <%--%>--%>
-
-    <%--<h3>Version <%=versionPath.getVersionNumber()%></h3>--%>
-
-    <%--<strong style="color:#696969;">Last Modified:</strong><br>--%>
-    <%--<%=versionPath.getUpdatedOn().toString()%>--%>
-    <%--<br><strong style="color:#696969;">By:</strong> 
<%=versionPath.getUpdater()%>--%>
-    <%--<br>--%>
-    <%--<div style="margin-bottom:10px;">--%>
-        <%--<a 
href="/wso2registry/web<%=versionPath.getCompleteVersionPath()%>" 
title="Details">Details <img src="/wso2registry/admin/images/icon-details.gif" 
border="0" hspace="3" /></a>--%>
-        <%--<a href="#" title="Restore" style="margin-left:5px;">Restore <img 
src="/wso2registry/admin/images/icon-restore.gif" border="0" /></a>--%>
-    <%--</div>--%>
+<%--<%--%>
+<%--Iterator iVersions = details.getVersionPaths().iterator();--%>
+<%--while (iVersions.hasNext()) {--%>
+<%--VersionPath versionPath = (VersionPath) iVersions.next();--%>
+<%--%>--%>
+
+<%--<h3>Version <%=versionPath.getVersionNumber()%></h3>--%>
+
+<%--<strong style="color:#696969;">Last Modified:</strong><br>--%>
+<%--<%=versionPath.getUpdatedOn().toString()%>--%>
+<%--<br><strong style="color:#696969;">By:</strong> 
<%=versionPath.getUpdater()%>--%>
+<%--<br>--%>
+<%--<div style="margin-bottom:10px;">--%>
+<%--<a href="/wso2registry/web<%=versionPath.getCompleteVersionPath()%>" 
title="Details">Details <img src="/wso2registry/admin/images/icon-details.gif" 
border="0" hspace="3" /></a>--%>
+<%--<a href="#" title="Restore" style="margin-left:5px;">Restore <img 
src="/wso2registry/admin/images/icon-restore.gif" border="0" /></a>--%>
+<%--</div>--%>
 
 
-    <%--<% } %>--%>
+<%--<% } %>--%>
 <%--</div>--%>
 <%--<div class="box2-bot">--%>
-    <%--<table cellspacing="0" cellpadding="0" border="0" style="width:100%" 
>--%>
-        <%--<tr>--%>
-            <%--<td><img src="/wso2registry/admin/images/box2-leftbot.jpg" 
/></td>--%>
-            <%--<td align="right"><img 
src="/wso2registry/admin/images/box2-rightbot.jpg" /></td>--%>
-        <%--</tr>--%>
-    <%--</table>--%>
+<%--<table cellspacing="0" cellpadding="0" border="0" style="width:100%" >--%>
+<%--<tr>--%>
+<%--<td><img src="/wso2registry/admin/images/box2-leftbot.jpg" /></td>--%>
+<%--<td align="right"><img src="/wso2registry/admin/images/box2-rightbot.jpg" 
/></td>--%>
+<%--</tr>--%>
+<%--</table>--%>
 <%--</div>--%>
 
 <%--</td>--%>

_______________________________________________
Registry-dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/registry-dev

Reply via email to