Class MainUriResolveStrategyImpl

java.lang.Object
ch.tocco.nice2.dms.impl.tree.uri.MainUriResolveStrategyImpl
All Implemented Interfaces:
MainUriResolveStrategy

@Component @Order(200) public class MainUriResolveStrategyImpl extends Object implements MainUriResolveStrategy
This URI resolve strategy tries to resolve a domain (by URL and alias field) and from this point on step by step the remaining URI (only taking the name of the subnodes into account). An example: Given domain/page structure: "Example domain" (with url "https://www.example.com" and "http://www.example.com" +- "Subpage1" (with name "subpage1") +- "Subpage2" (with name "subpage2") Requested URL: "http://www.example.com/subpage1/subpage2" Steps: 1. Try to find domain with following URLs: 1. http://www.example.com 2. http://www.example.com/subpage1 3. http://www.example.com/subpage1/subpage2 2. Since the domain can be found with the first URL http://www.example.com the first step is aborted after this URL 3. The remaining URL is: "subpage1/subpage2" 4. Try to find child of domain with name "subpage1" 5. If step 4 has been successful try to find a child of the resolved child (step 4) with name "subpage2" 6. If step 5 has been successful, return the child with name "subpage2" 7. If one of steps 1-6 fails: return Optional.empty();
  • Field Details

  • Constructor Details

    • MainUriResolveStrategyImpl

      public MainUriResolveStrategyImpl(ContentTreeService contentTreeService, org.slf4j.Logger log)
  • Method Details