Package com.github.mrcritical.ironcache.internal.model.requests

Examples of com.github.mrcritical.ironcache.internal.model.requests.CacheUrl


  @Override
  public void deleteCache(final String name) {
    try {

      final CacheResponse response = objectMapper.readValue(
          requestFactory.buildDeleteRequest(new CacheUrl(hostName, projectId, name)).execute().getContent(),
          CacheResponse.class);

      validate(response, "deleted");

    } catch (final Exception e) {
View Full Code Here


  @Override
  public Optional<Cache> getCache(final String name) {
    try {

      return Optional.fromNullable(objectMapper.readValue(
          requestFactory.buildGetRequest(new CacheUrl(hostName, projectId, name)).execute().getContent(),
          Cache.class));

    } catch (final HTTPException e) {
      if (e.getStatusCode() == 404) {
        return Optional.absent();
View Full Code Here

TOP

Related Classes of com.github.mrcritical.ironcache.internal.model.requests.CacheUrl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.