Project

General

Profile

« Previous | Next » 

Revision 5394

Added by berkley almost 14 years ago

tracked down streaming bug. now need to figure out a better way to fix it.

View differences:

CrudService.java
87 87
 * 
88 88
 * @author Matthew Jones
89 89
 */
90
public class CrudService implements MemberNodeCrud {
91

  
92
    /*private ServletContext servletContext;
93
    private HttpServletRequest request;
94
    private HttpServletResponse response;*/
95
    
90
public class CrudService implements MemberNodeCrud
91
{
96 92
    private static CrudService crudService = null;
97 93

  
98 94
    private MetacatHandler handler;
......
117 113
    
118 114
    /**
119 115
     * Initializes new instance by setting servlet context,request and response.
120
     * TODO: remove dependency on Servlet infrastructure
121
     * TODO: Make this a real service, and make it a Singleton
122 116
     */
123 117
    public CrudService() {
124 118
    //change crud service into a singleton.  dont pass servlet data structures here
......
158 152
    }
159 153
    
160 154
    /**
155
     * Set the context url that this service uses.  It is normally not necessary
156
     * to call this method unless you are trying to connect to a server other
157
     * than the one in which this service is installed.  Otherwise, this value is
158
     * taken from the metacat.properties file (server.name, server.port, application.context).
159
     */
160
    public void setContextUrl(String url)
161
    {
162
        metacatUrl = url;
163
    }
164
    
165
    /**
161 166
     * set the params for this service from an HttpServletRequest param list
162 167
     */
163 168
    public void setParamsFromRequest(HttpServletRequest request)
......
912 917
     * If the session has expired or is invalid, the 'public' session will
913 918
     * be returned, giving the user anonymous access.
914 919
     */
915
    protected static SessionData getSessionData(AuthToken token) {
920
    public static SessionData getSessionData(AuthToken token) {
916 921
        SessionData sessionData = null;
917 922
        String sessionId = "PUBLIC";
918 923
        if (token != null) {

Also available in: Unified diff