001/* 002 * The contents of this file are subject to the terms of the Common Development and 003 * Distribution License (the License). You may not use this file except in compliance with the 004 * License. 005 * 006 * You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the 007 * specific language governing permission and limitations under the License. 008 * 009 * When distributing Covered Software, include this CDDL Header Notice in each file and include 010 * the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL 011 * Header, with the fields enclosed by brackets [] replaced by your own identifying 012 * information: "Portions Copyright [year] [name of copyright owner]". 013 * 014 * Copyright 2008 Sun Microsystems, Inc. 015 */ 016package org.forgerock.opendj.server.config.client; 017 018 019 020import java.util.Collection; 021import java.util.SortedSet; 022import org.forgerock.opendj.config.ConfigurationClient; 023import org.forgerock.opendj.config.ManagedObjectDefinition; 024import org.forgerock.opendj.config.PropertyException; 025import org.forgerock.opendj.server.config.server.HTTPEndpointCfg; 026 027 028 029/** 030 * A client-side interface for reading and modifying HTTP Endpoint 031 * settings. 032 * <p> 033 * The HTTP Endpoint is used to define HTTP endpoint. 034 */ 035public interface HTTPEndpointCfgClient extends ConfigurationClient { 036 037 /** 038 * Get the configuration definition associated with this HTTP Endpoint. 039 * 040 * @return Returns the configuration definition associated with this HTTP Endpoint. 041 */ 042 ManagedObjectDefinition<? extends HTTPEndpointCfgClient, ? extends HTTPEndpointCfg> definition(); 043 044 045 046 /** 047 * Gets the "authorization-mechanism" property. 048 * <p> 049 * The HTTP authorization mechanisms supported by this HTTP 050 * Endpoint. 051 * 052 * @return Returns the values of the "authorization-mechanism" property. 053 */ 054 SortedSet<String> getAuthorizationMechanism(); 055 056 057 058 /** 059 * Sets the "authorization-mechanism" property. 060 * <p> 061 * The HTTP authorization mechanisms supported by this HTTP 062 * Endpoint. 063 * 064 * @param values The values of the "authorization-mechanism" property. 065 * @throws PropertyException 066 * If one or more of the new values are invalid. 067 */ 068 void setAuthorizationMechanism(Collection<String> values) throws PropertyException; 069 070 071 072 /** 073 * Gets the "base-path" property. 074 * <p> 075 * All HTTP requests matching the base path or subordinate to it 076 * will be routed to the HTTP endpoint unless a more specific HTTP 077 * endpoint is found. 078 * 079 * @return Returns the value of the "base-path" property. 080 */ 081 String getBasePath(); 082 083 084 085 /** 086 * Sets the "base-path" property. 087 * <p> 088 * All HTTP requests matching the base path or subordinate to it 089 * will be routed to the HTTP endpoint unless a more specific HTTP 090 * endpoint is found. 091 * <p> 092 * This property is read-only and can only be modified during 093 * creation of a HTTP Endpoint. 094 * 095 * @param value The value of the "base-path" property. 096 * @throws PropertyException 097 * If the new value is invalid. 098 * @throws PropertyException 099 * If this HTTP Endpoint is not being initialized. 100 */ 101 void setBasePath(String value) throws PropertyException, PropertyException; 102 103 104 105 /** 106 * Gets the "enabled" property. 107 * <p> 108 * Indicates whether the HTTP Endpoint is enabled. 109 * 110 * @return Returns the value of the "enabled" property. 111 */ 112 Boolean isEnabled(); 113 114 115 116 /** 117 * Sets the "enabled" property. 118 * <p> 119 * Indicates whether the HTTP Endpoint is enabled. 120 * 121 * @param value The value of the "enabled" property. 122 * @throws PropertyException 123 * If the new value is invalid. 124 */ 125 void setEnabled(boolean value) throws PropertyException; 126 127 128 129 /** 130 * Gets the "java-class" property. 131 * <p> 132 * Specifies the fully-qualified name of the Java class that 133 * provides the HTTP Endpoint implementation. 134 * 135 * @return Returns the value of the "java-class" property. 136 */ 137 String getJavaClass(); 138 139 140 141 /** 142 * Sets the "java-class" property. 143 * <p> 144 * Specifies the fully-qualified name of the Java class that 145 * provides the HTTP Endpoint implementation. 146 * 147 * @param value The value of the "java-class" property. 148 * @throws PropertyException 149 * If the new value is invalid. 150 */ 151 void setJavaClass(String value) throws PropertyException; 152 153}