Class HubService

java.lang.Object
io.meeds.deeds.common.service.HubService

@Component public class HubService extends Object
  • Field Details

  • Constructor Details

    • HubService

      public HubService()
  • Method Details

    • init

      @PostConstruct public void init()
    • getHubs

      public org.springframework.data.domain.Page<io.meeds.wom.api.model.Hub> getHubs(org.springframework.data.domain.Pageable pageable)
    • getHubs

      public org.springframework.data.domain.Page<io.meeds.wom.api.model.Hub> getHubs(long rewardId, org.springframework.data.domain.Pageable pageable)
    • getHub

      public io.meeds.wom.api.model.Hub getHub(Long nftId)
    • getHub

      public io.meeds.wom.api.model.Hub getHub(String hubAddress)
    • getHub

      public io.meeds.wom.api.model.Hub getHub(String hubAddress, boolean forceRefresh)
    • refreshHubFromWom

      public io.meeds.wom.api.model.Hub refreshHubFromWom(String hubAddress)
    • refreshClaimableAmount

      public void refreshClaimableAmount(String address)
    • generateToken

      public String generateToken(String clientIp)
    • connectToWom

      public io.meeds.wom.api.model.WomConnectionResponse connectToWom(io.meeds.wom.api.model.WomConnectionRequest hubConnectionRequest) throws io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.WomException
    • disconnectFromWom

      public String disconnectFromWom(io.meeds.wom.api.model.WomDisconnectionRequest hubDisconnectionRequest) throws io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.WomException
    • updateHub

      public void updateHub(io.meeds.wom.api.model.HubUpdateRequest hubUpdateRequest) throws io.meeds.wom.api.constant.WomException, io.meeds.wom.api.constant.ObjectNotFoundException
      Throws:
      io.meeds.wom.api.constant.WomException
      io.meeds.wom.api.constant.ObjectNotFoundException
    • saveHubAvatar

      public void saveHubAvatar(String hubAddress, String signedMessage, String rawMessage, String token, org.springframework.web.multipart.MultipartFile file) throws io.meeds.wom.api.constant.ObjectNotFoundException, io.meeds.wom.api.constant.WomException, IOException
      Throws:
      io.meeds.wom.api.constant.ObjectNotFoundException
      io.meeds.wom.api.constant.WomException
      IOException
    • getHubAvatar

      public FileBinary getHubAvatar(String hubAddress)
    • refreshHubUemProperties

      public void refreshHubUemProperties(String hubAddress)
    • getManagedDeeds

      public List<ManagedDeed> getManagedDeeds(String address)
    • updateDeedOnWom

      public boolean updateDeedOnWom(long deedId) throws io.meeds.wom.api.constant.ObjectNotFoundException, io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.ObjectNotFoundException
      io.meeds.wom.api.constant.WomException
    • updateDeedOnWom

      public boolean updateDeedOnWom(long deedId, boolean forceRefresh) throws io.meeds.wom.api.constant.ObjectNotFoundException, io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.ObjectNotFoundException
      io.meeds.wom.api.constant.WomException
    • autoConnectHubToWom

      public void autoConnectHubToWom(String hubAddress, long deedId) throws io.meeds.wom.api.constant.ObjectNotFoundException, io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.ObjectNotFoundException
      io.meeds.wom.api.constant.WomException
    • transferDeedOwner

      public void transferDeedOwner(long deedId, String previousOwner, String newOwner) throws io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.WomException
    • transferDeedManager

      public void transferDeedManager(long deedId, String previousManager, String newManager) throws io.meeds.wom.api.constant.WomException
      Throws:
      io.meeds.wom.api.constant.WomException
    • cleanTokens

      protected void cleanTokens()