javax.ws.rs.Consumes#javax.ws.rs.core.UriInfo源码实例Demo

下面列出了javax.ws.rs.Consumes#javax.ws.rs.core.UriInfo 实例代码,或者点击链接到github查看源代码,也可以在右侧发表评论。

源代码1 项目: keycloak   文件: AbstractOAuth2IdentityProvider.java
protected Response exchangeSessionToken(UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) {
    String accessToken = tokenUserSession.getNote(FEDERATED_ACCESS_TOKEN);
    if (accessToken == null) {
        event.detail(Details.REASON, "requested_issuer is not linked");
        event.error(Errors.INVALID_TOKEN);
        return exchangeTokenExpired(uriInfo, authorizedClient, tokenUserSession, tokenSubject);
    }
    AccessTokenResponse tokenResponse = new AccessTokenResponse();
    tokenResponse.setToken(accessToken);
    tokenResponse.setIdToken(null);
    tokenResponse.setRefreshToken(null);
    tokenResponse.setRefreshExpiresIn(0);
    tokenResponse.getOtherClaims().clear();
    tokenResponse.getOtherClaims().put(OAuth2Constants.ISSUED_TOKEN_TYPE, OAuth2Constants.ACCESS_TOKEN_TYPE);
    tokenResponse.getOtherClaims().put(ACCOUNT_LINK_URL, getLinkingUrl(uriInfo, authorizedClient, tokenUserSession));
    event.success();
    return Response.ok(tokenResponse).type(MediaType.APPLICATION_JSON_TYPE).build();
}
 
@Override
public List<UserOperationLogEntryDto> queryUserOperationEntries(UriInfo uriInfo, Integer firstResult, Integer maxResults) {
  UserOperationLogQueryDto queryDto = new UserOperationLogQueryDto(objectMapper, uriInfo.getQueryParameters());
  UserOperationLogQuery query = queryDto.toQuery(processEngine);

  if (firstResult == null && maxResults == null) {
    return UserOperationLogEntryDto.map(query.list());
  } else {
    if (firstResult == null) {
      firstResult = 0;
    }
    if (maxResults == null) {
      maxResults = Integer.MAX_VALUE;
    }
    return UserOperationLogEntryDto.map(query.listPage(firstResult, maxResults));
  }
}
 
源代码3 项目: trellis   文件: TrellisHttpResource.java
/**
 * Perform a POST operation on a LDP Resource.
 *
 * @param uriInfo the URI info
 * @param secContext the security context
 * @param headers the HTTP headers
 * @param request the request
 * @param body the body
 * @return the async response
 */
@POST
@Timed
@Operation(summary = "Create a linked data resource")
public CompletionStage<Response> createResource(@Context final Request request, @Context final UriInfo uriInfo,
        @Context final HttpHeaders headers, @Context final SecurityContext secContext,
        @RequestBody(description = "The new resource") final InputStream body) {
    final TrellisRequest req = new TrellisRequest(request, uriInfo, headers, secContext);
    final String urlBase = getBaseUrl(req);
    final String path = req.getPath();
    final String identifier = getIdentifier(req);
    final String separator = path.isEmpty() ? "" : "/";

    final IRI parent = buildTrellisIdentifier(path);
    final IRI child = buildTrellisIdentifier(path + separator + identifier);
    final PostHandler postHandler = new PostHandler(req, parent, identifier, body, trellis, extensions, urlBase);

    return trellis.getResourceService().get(parent)
        .thenCombine(trellis.getResourceService().get(child), postHandler::initialize)
        .thenCompose(postHandler::createResource).thenCompose(postHandler::updateMemento)
        .thenApply(ResponseBuilder::build).exceptionally(this::handleException);
}
 
源代码4 项目: io   文件: AbstractODataResource.java
/**
 * レスポンスボディを作成する.
 * @param uriInfo UriInfo
 * @param resp レスポンス
 * @param format レスポンスボディのフォーマット
 * @param acceptableMediaTypes 許可するMediaTypeのリスト
 * @return レスポンスボディ
 */
protected String renderEntityResponse(
        final UriInfo uriInfo,
        final EntityResponse resp,
        final String format,
        final List<MediaType> acceptableMediaTypes) {
    StringWriter w = new StringWriter();
    try {
        FormatWriter<EntityResponse> fw = DcFormatWriterFactory.getFormatWriter(EntityResponse.class,
                acceptableMediaTypes, format, null);
        // UriInfo uriInfo2 = DcCoreUtils.createUriInfo(uriInfo, 1);
        fw.write(uriInfo, w, resp);
    } catch (UnsupportedOperationException e) {
        throw DcCoreException.OData.FORMAT_INVALID_ERROR.params(format);
    }

    String responseStr = w.toString();

    return responseStr;

}
 
源代码5 项目: registry   文件: SchemaRegistryResource.java
@GET
@Path("/search/schemas")
@ApiOperation(value = "Search for schemas containing the given name and description",
        notes = "Search the schemas for given name and description, return a list of schemas that contain the field.",
        response = SchemaMetadataInfo.class, responseContainer = "List", tags = OPERATION_GROUP_SCHEMA)
@Timed
@UnitOfWork
public Response findSchemas(@Context UriInfo uriInfo,
                            @Context SecurityContext securityContext) {
    MultivaluedMap<String, String> queryParameters = uriInfo.getQueryParameters();
    try {
        Collection<SchemaMetadataInfo> schemaMetadataInfos = authorizationAgent
                .authorizeFindSchemas(AuthorizationUtils.getUserAndGroups(securityContext), findSchemaMetadataInfos(queryParameters));
        return WSUtils.respondEntities(schemaMetadataInfos, Response.Status.OK);
    } catch (Exception ex) {
        LOG.error("Encountered error while finding schemas for given fields [{}]", queryParameters, ex);
        return WSUtils.respond(Response.Status.INTERNAL_SERVER_ERROR, CatalogResponse.ResponseMessage.EXCEPTION, ex.getMessage());
    }
}
 
源代码6 项目: proarc   文件: DigitalObjectResource.java
public DigitalObjectResource(
        @Context Request request,
        @Context SecurityContext securityCtx,
        @Context HttpHeaders httpHeaders,
        @Context UriInfo uriInfo,
        @Context HttpServletRequest httpRequest
        ) throws AppConfigurationException {
    
    this.httpRequest = request;
    this.httpHeaders = httpHeaders;
    this.appConfig = AppConfigurationFactory.getInstance().defaultInstance();
    this.importManager = ImportBatchManager.getInstance(appConfig);
    session = SessionContext.from(httpRequest);
    user = session.getUser();
    LOG.fine(user.toString());
}
 
源代码7 项目: io   文件: ODataLinksResource.java
QueryInfo queryInfo(UriInfo uriInfo) {
    MultivaluedMap<String, String> mm = uriInfo.getQueryParameters(true);
    Integer top = QueryParser.parseTopQuery(mm.getFirst("$top"));
    Integer skip = QueryParser.parseSkipQuery(mm.getFirst("$skip"));

    return new QueryInfo(
            null,
            top,
            skip,
            null,
            null,
            null,
            null,
            null,
            null);
}
 
源代码8 项目: govpay   文件: ProfiloController.java
public Response profiloGET(Authentication user, UriInfo uriInfo, HttpHeaders httpHeaders) {
  	String methodName = "profiloGET";  
String transactionId = ContextThreadLocal.get().getTransactionId();
this.log.debug(MessageFormat.format(BaseController.LOG_MSG_ESECUZIONE_METODO_IN_CORSO, methodName)); 
try{
	UtentiDAO utentiDAO = new UtentiDAO();
	
	LeggiProfiloDTOResponse leggiProfilo = utentiDAO.getProfilo(user);

	Profilo profilo = ProfiloConverter.getProfilo(leggiProfilo);

	this.log.debug(MessageFormat.format(BaseController.LOG_MSG_ESECUZIONE_METODO_COMPLETATA, methodName)); 
	return this.handleResponseOk(Response.status(Status.OK).entity(profilo.toJSON(null)),transactionId).build();
	
}catch (Exception e) {
	return this.handleException(uriInfo, httpHeaders, methodName, e, transactionId);
} finally {
	this.log(ContextThreadLocal.get());
}
  }
 
源代码9 项目: crnk-framework   文件: CrnkFilterTest.java
@Test
public void checkWebPathPrefixWrongNoFilter() throws IOException {
	CrnkFeature feature = Mockito.mock(CrnkFeature.class);
	Mockito.when(feature.getWebPathPrefix()).thenReturn("api");
	Mockito.when(feature.getBoot()).thenThrow(new WebApplicationException("test"));

	CrnkFilter filter = new CrnkFilter(feature);
	UriInfo uriInfo = Mockito.mock(UriInfo.class);
	Mockito.when(uriInfo.getPath()).thenReturn("/api2/tasks");
	Mockito.when(uriInfo.getQueryParameters()).thenReturn(Mockito.mock(MultivaluedMap.class));

	ContainerRequestContext requestContext = Mockito.mock(ContainerRequestContext.class);
	Mockito.when(requestContext.getUriInfo()).thenReturn(uriInfo);
	try {
		filter.filter(requestContext);
	} catch (WebApplicationException e) {
		Assert.fail();
	}
}
 
源代码10 项目: usergrid   文件: ApplicationResource.java
@RequireOrganizationAccess
@GET
@JSONP
@Produces({MediaType.APPLICATION_JSON, "application/javascript"})
public ApiResponse getApplication(
        @Context UriInfo ui, @QueryParam("callback") @DefaultValue("callback") String callback )
    throws Exception {

    ApiResponse response = createApiResponse();
    ServiceManager sm = smf.getServiceManager( applicationId );
    response.setAction( "get" );
    response.setApplication( sm.getApplication() );
    response.setParams( ui.getQueryParameters() );
    response.setResults( management.getApplicationMetadata( applicationId ) );
    return response;
}
 
源代码11 项目: govpay   文件: ConfigurazioniController.java
public Response addConfigurazioni(Authentication user, UriInfo uriInfo, HttpHeaders httpHeaders , java.io.InputStream is) {
  	String methodName = "addConfigurazioni";  
String transactionId = ContextThreadLocal.get().getTransactionId();
this.log.debug(MessageFormat.format(BaseController.LOG_MSG_ESECUZIONE_METODO_IN_CORSO, methodName)); 
try(ByteArrayOutputStream baos= new ByteArrayOutputStream();){
	// salvo il json ricevuto
	IOUtils.copy(is, baos);

	// autorizzazione sulla API
	this.isAuthorized(user, Arrays.asList(TIPO_UTENZA.OPERATORE, TIPO_UTENZA.APPLICAZIONE), Arrays.asList(Servizio.CONFIGURAZIONE_E_MANUTENZIONE), Arrays.asList(Diritti.SCRITTURA));

	String jsonRequest = baos.toString();
	Configurazione giornaleRequest= JSONSerializable.parse(jsonRequest, Configurazione.class);

	giornaleRequest.validate();

	PutConfigurazioneDTO putConfigurazioneDTO = ConfigurazioniConverter.getPutConfigurazioneDTO(giornaleRequest, user); 

	ConfigurazioneDAO configurazioneDAO = new ConfigurazioneDAO(false);

	PutConfigurazioneDTOResponse putConfigurazioneDTOResponse = configurazioneDAO.salvaConfigurazione(putConfigurazioneDTO);
	Status responseStatus = putConfigurazioneDTOResponse.isCreated() ?  Status.CREATED : Status.OK;

	this.log.debug(MessageFormat.format(BaseController.LOG_MSG_ESECUZIONE_METODO_COMPLETATA, methodName)); 
	return this.handleResponseOk(Response.status(responseStatus),transactionId).build();
}catch (Exception e) {
	return this.handleException(uriInfo, httpHeaders, methodName, e, transactionId);
} finally {
	this.log(ContextThreadLocal.get());
}
  }
 
源代码12 项目: jaxrs-hypermedia   文件: EntityBuilder.java
public Entity buildOrders(List<Order> orders, UriInfo uriInfo) {
    final List<Entity> orderEntities = orders.stream().map(o -> buildOrderTeaser(o, uriInfo)).collect(Collectors.toList());

    return createEntityBuilder().setComponentClass("orders")
            .addLink(linkBuilder.forOrders(uriInfo))
            .addSubEntities(orderEntities).build();
}
 
源代码13 项目: govpay   文件: Tracciati.java
@GET
@Path("/{id}/richiesta")

@Produces({ "application/octet-stream" })
public Response getMessaggioRichiestaTracciato(@Context UriInfo uriInfo, @Context HttpHeaders httpHeaders, @PathParam("id") Long id){
    this.buildContext();
    return this.controller.getMessaggioRichiestaTracciato(this.getUser(), uriInfo, httpHeaders,  id);
}
 
源代码14 项目: activemq-artemis   文件: ConsumersResource.java
@Path("attributes-{attributes}/{consumer-id}")
@DELETE
public void closeSession(@PathParam("consumer-id") String consumerId, @Context UriInfo uriInfo) {
   ActiveMQRestLogger.LOGGER.debug("Handling DELETE request for \"" + uriInfo.getPath() + "\"");

   QueueConsumer consumer = queueConsumers.remove(consumerId);
   if (consumer == null) {
      throw new WebApplicationException(Response.status(Response.Status.NOT_FOUND).entity("Failed to match a consumer to URL" + consumerId).type("text/plain").build());
   }
   consumer.shutdown();
}
 
源代码15 项目: olingo-odata4   文件: Services.java
@GET
@Path("/Boss")
public Response getSingletonBoss(
    @Context final UriInfo uriInfo,
    @HeaderParam("Accept") @DefaultValue(StringUtils.EMPTY) final String accept,
    @QueryParam("$format") @DefaultValue(StringUtils.EMPTY) final String format) {

  return getEntityInternal(
      uriInfo.getRequestUri().toASCIIString(), accept, "Boss", StringUtils.EMPTY, format, null, null);
}
 
源代码16 项目: cxf   文件: ResponseBuilderImpl.java
public ResponseBuilder location(URI loc) {
    if (!loc.isAbsolute()) {
        Message currentMessage = PhaseInterceptorChain.getCurrentMessage();
        if (currentMessage != null) {

            UriInfo ui = new UriInfoImpl(currentMessage.getExchange().getInMessage(), null);
            loc = ui.getBaseUriBuilder()
                    .path(loc.getRawPath())
                    .replaceQuery(loc.getRawQuery())
                    .fragment(loc.getRawFragment()).buildFromEncoded();
        }
    }
    return setHeader(HttpHeaders.LOCATION, loc);
}
 
源代码17 项目: keycloak   文件: AuthenticationManager.java
public static String nextRequiredAction(final KeycloakSession session, final AuthenticationSessionModel authSession,
                                        final ClientConnection clientConnection,
                                        final HttpRequest request, final UriInfo uriInfo, final EventBuilder event) {
    final RealmModel realm = authSession.getRealm();
    final UserModel user = authSession.getAuthenticatedUser();
    final ClientModel client = authSession.getClient();

    evaluateRequiredActionTriggers(session, authSession, clientConnection, request, uriInfo, event, realm, user);

    if (!user.getRequiredActions().isEmpty()) {
        return user.getRequiredActions().iterator().next();
    }
    if (!authSession.getRequiredActions().isEmpty()) {
        return authSession.getRequiredActions().iterator().next();
    }

    String kcAction = authSession.getClientNote(Constants.KC_ACTION);
    if (kcAction != null) {
        return kcAction;
    }

    if (client.isConsentRequired()) {

        UserConsentModel grantedConsent = getEffectiveGrantedConsent(session, authSession);

        // See if any clientScopes need to be approved on consent screen
        List<ClientScopeModel> clientScopesToApprove = getClientScopesToApproveOnConsentScreen(realm, grantedConsent, authSession);
        if (!clientScopesToApprove.isEmpty()) {
            return CommonClientSessionModel.Action.OAUTH_GRANT.name();
        }

        String consentDetail = (grantedConsent != null) ? Details.CONSENT_VALUE_PERSISTED_CONSENT : Details.CONSENT_VALUE_NO_CONSENT_REQUIRED;
        event.detail(Details.CONSENT, consentDetail);
    } else {
        event.detail(Details.CONSENT, Details.CONSENT_VALUE_NO_CONSENT_REQUIRED);
    }
    return null;

}
 
源代码18 项目: agrest   文件: GET_ConstraintsIT.java
@GET
@Path("e4/limit_attributes")
public DataResponse<E4> getObjects_LimitAttributes(@Context UriInfo uriInfo) {
    return Ag.select(E4.class, config).uri(uriInfo)
            .constraint(Constraint.idOnly(E4.class).attributes(E4.C_INT))
            .get();
}
 
源代码19 项目: streamline   文件: ComponentCatalogResource.java
private List<QueryParam> buildServiceIdAwareQueryParams(Long serviceId, UriInfo uriInfo) {
    List<QueryParam> queryParams = new ArrayList<>();
    queryParams.add(new QueryParam("serviceId", serviceId.toString()));
    if (uriInfo != null) {
        MultivaluedMap<String, String> params = uriInfo.getQueryParameters();
        if (!params.isEmpty()) {
            queryParams.addAll(WSUtils.buildQueryParameters(params));
        }
    }

    return queryParams;
}
 
源代码20 项目: govpay   文件: DominiController.java
public Response dominiIdDominioGET(Authentication user, UriInfo uriInfo, HttpHeaders httpHeaders , String idDominio) {
  	String methodName = "dominiIdDominioGET";  
String transactionId = ContextThreadLocal.get().getTransactionId();
this.log.debug(MessageFormat.format(BaseController.LOG_MSG_ESECUZIONE_METODO_IN_CORSO, methodName)); 
try{
	// autorizzazione sulla API
	this.isAuthorized(user, Arrays.asList(TIPO_UTENZA.ANONIMO, TIPO_UTENZA.CITTADINO, TIPO_UTENZA.APPLICAZIONE), Arrays.asList(Servizio.API_PAGAMENTI), Arrays.asList(Diritti.LETTURA));

	ValidatoreIdentificativi validatoreId = ValidatoreIdentificativi.newInstance();
	validatoreId.validaIdDominio("idDominio", idDominio);
	
	// Parametri - > DTO Input
	
	GetDominioDTO getDominioDTO = new GetDominioDTO(user, idDominio);

	// INIT DAO
	
	DominiDAO dominiDAO = new DominiDAO();
	
	// CHIAMATA AL DAO
	
	GetDominioDTOResponse listaDominiDTOResponse = dominiDAO.getDominio(getDominioDTO);
	
	// CONVERT TO JSON DELLA RISPOSTA
	
	it.govpay.pagamento.v2.beans.Dominio response = DominiConverter.toRsModel(listaDominiDTOResponse.getDominio(), listaDominiDTOResponse.getUo(), listaDominiDTOResponse.getTributi(), listaDominiDTOResponse.getIban());
	
	this.log.debug(MessageFormat.format(BaseController.LOG_MSG_ESECUZIONE_METODO_COMPLETATA, methodName)); 
	return this.handleResponseOk(Response.status(Status.OK).entity(response.toJSON(null)),transactionId).build();
	
}catch (Exception e) {
	return this.handleException(uriInfo, httpHeaders, methodName, e, transactionId);
} finally {
	this.log(ContextThreadLocal.get());
}
  }
 
源代码21 项目: govpay   文件: Intermediari.java
@PUT
@Path("/{idIntermediario}")
@Consumes({ "application/json" })

public Response addIntermediario(@Context UriInfo uriInfo, @Context HttpHeaders httpHeaders, @PathParam("idIntermediario") String idIntermediario, java.io.InputStream is){
    this.buildContext();
    return this.controller.addIntermediario(this.getUser(), uriInfo, httpHeaders,  idIntermediario, is);
}
 
源代码22 项目: streamline   文件: TopologyEdgeCatalogResource.java
@GET
@Path("/topologies/{topologyId}/versions/{versionId}/edges")
@Timed
public Response listTopologyEdgesForVersion(@PathParam("topologyId") Long topologyId,
                                            @PathParam("versionId") Long versionId,
                                            @Context UriInfo uriInfo,
                                            @Context SecurityContext securityContext) throws Exception {
    return listTopologyEdges(
            buildTopologyIdAndVersionIdAwareQueryParams(topologyId, versionId, uriInfo),
            topologyId,
            securityContext);
}
 
源代码23 项目: usergrid   文件: ManagementResource.java
@POST
@Path( "me" )
@Consumes( APPLICATION_JSON )
public Response getAccessTokenMePostJson( @Context UriInfo ui, Map<String, Object> json,
                                          @QueryParam( "callback" ) @DefaultValue( "" ) String callback,
                                          @HeaderParam( "Authorization" ) String authorization ) throws Exception {


    ValidateJson(json);

    String grant_type = ( String ) json.get( "grant_type" );
    String username = ( String ) json.get( "username" );
    String password = ( String ) json.get( "password" );
    String client_id = ( String ) json.get( "client_id" );
    String client_secret = ( String ) json.get( "client_secret" );
    long ttl = 0;

    if ( json.get( "ttl" ) != null ) {
        try {
            ttl = Long.parseLong( json.get( "ttl" ).toString() );
        }
        catch ( NumberFormatException nfe ) {
            throw new IllegalArgumentException( "ttl must be a number >= 0" );
        }
    }

    return getAccessTokenInternal( ui, authorization, grant_type, username, password, client_id, client_secret, ttl,
            callback, false, false );
}
 
源代码24 项目: govpay   文件: Riscossioni.java
@GET
@Path("/{idDominio}/{iuv}/{iur}/{indice}")

@Produces({ "application/json" })
public Response getRiscossione(@Context UriInfo uriInfo, @Context HttpHeaders httpHeaders, @PathParam("idDominio") String idDominio, @PathParam("iuv") String iuv, @PathParam("iur") String iur, @PathParam("indice") Integer indice){
    this.buildContext();
    return this.controller.riscossioniIdDominioIuvIurIndiceGET(this.getUser(), uriInfo, httpHeaders,  idDominio,  iuv,  iur,  indice);
}
 
源代码25 项目: datacollector   文件: GatewayBaseResource.java
@Path("/{subResources: .*}")
@GET
public Response handleGetRequests(
    @PathParam("subResources") String subResources,
    @Context UriInfo uriInfo,
    @Context HttpHeaders httpheaders
) throws PipelineException {
  return proxyRequest(subResources, uriInfo, HttpMethod.GET, httpheaders, null);
}
 
源代码26 项目: govpay   文件: Rpp.java
@PATCH
@Path("/{idDominio}/{iuv}/n/a")
@Consumes({ "application/json" })
@Produces({ "application/json" })
public Response updateRpp(@Context UriInfo uriInfo, @Context HttpHeaders httpHeaders, java.io.InputStream is, @PathParam("idDominio") String idDominio, @PathParam("iuv") String iuv){
    this.buildContext();
    return this.controller.updateRpp(this.getUser(), uriInfo, httpHeaders, is,  idDominio,  iuv,  "n/a");
}
 
源代码27 项目: olingo-odata4   文件: OpenType.java
@POST
@Path("/{entitySetName}")
@Produces({ MediaType.APPLICATION_XML, MediaType.APPLICATION_ATOM_XML, MediaType.APPLICATION_JSON })
@Consumes({ MediaType.APPLICATION_ATOM_XML, MediaType.APPLICATION_JSON, MediaType.APPLICATION_OCTET_STREAM })
@Override
public Response postNewEntity(
    @Context final UriInfo uriInfo,
    @HeaderParam("Accept") @DefaultValue(StringUtils.EMPTY) final String accept,
    @HeaderParam("Content-Type") @DefaultValue(StringUtils.EMPTY) final String contentType,
    @HeaderParam("Prefer") @DefaultValue(StringUtils.EMPTY) final String prefer,
    @PathParam("entitySetName") final String entitySetName,
    final String entity) {

  return replaceServiceName(super.postNewEntity(uriInfo, accept, contentType, prefer, entitySetName, entity));
}
 
源代码28 项目: cxf   文件: Customer.java
public void testParams(@Context UriInfo info,
                       @Context HttpHeaders hs,
                       @Context Request r,
                       @Context SecurityContext s,
                       @Context Providers workers,
                       @HeaderParam("Foo") String h,
                       @HeaderParam("Foo") List<String> l) {
    // complete
}
 
源代码29 项目: hugegraph   文件: AuthenticationFilter.java
public Authorizer(final User user, final UriInfo uri) {
    E.checkNotNull(user, "user");
    E.checkNotNull(uri, "uri");
    this.uri = uri;
    this.user = user;
    this.principal = new UserPrincipal();
}
 
源代码30 项目: dexter   文件: RestService.java
private DexterLocalParams getLocalParams(UriInfo ui) {
	MultivaluedMap<String, String> queryParams = ui.getQueryParameters();
	DexterLocalParams params = new DexterLocalParams();
	for (String key : queryParams.keySet()) {
		params.addParam(key, queryParams.getFirst(key));
	}
	return params;
}