Package org.foafrealm.manage

Examples of org.foafrealm.manage.XResource


//    }
    Iterator<XResource> it = parent.listContent();
    List<String> urisIn = new ArrayList<String>()// list of resource uris that were already processed.
                            // used to filter for duplicate resources
    while(it.hasNext()){
      XResource childBr = it.next();
      XfoafSscfResource xres= XfoafSscfResource.getXfoafSscfResource(childBr.getStringURI());
      //recursive call to fetch bookmarks stored in subDirectory
      if(xres != null && xres.isDirectory()){
        result.addAll(loadPosts(xres));
      }else if(xres != null){
        if(!urisIn.contains(xres.getURI().toString())){
View Full Code Here


    XfoafSscfResource resource = XfoafSscfResource.getXfoafSscfResource(uri);
    Iterator<XResource> it = resource.listContent();
    List<XfoafSscfResource> ret = new ArrayList<XfoafSscfResource>();

    while (it.hasNext()) {
      XResource br = it.next();
      if(br instanceof XfoafSscfResource)
      {
        XfoafSscfResource res = (XfoafSscfResource)br;
        if (viewer != null) {
          if (checkCredit(viewer, res)) {
View Full Code Here

      DirectoryDescription dd = new DirectoryDescription();
     
      //Get name and description
      dd.setName(xsscf.getLabel());
      dd.setDescription(xsscf.getComment());
      XResource xfr = xsscf.getIssuedBy();
      if(xfr instanceof Person) {
        Person tmp = (Person)xfr;
        dd.setOwner(tmp.getName());
      }
     
View Full Code Here

      boolean isSuggested,boolean inOwn,String serviceAddr,String selectedUri,
      Set<List<String>> pathsToUri) {
    // FriendAuthentication fa = null;

    while (it.hasNext()) {
      XResource resource = it.next();

      if (resource instanceof SiocDataResource) {
        bookmarksTreeSiocData(resource, viewer, buffer, depth, session, it, level, parentIsOwner, standalone, inOwn,selectedUri,pathsToUri);
      }
      if (resource instanceof WebBookmarkResource)
View Full Code Here

      boolean isSuggested,boolean inOwn,String serviceAddr,String selectedUri,
      Set<List<String>> pathsToUri) {
   
    Person issuer = null;
    int level = _level;
    XResource xfr = resource.getIssuedBy();
    if(xfr instanceof Person)
      issuer = (Person)xfr;
   
    boolean isDir = resource.isDirectory();
    boolean isOwner = false;
View Full Code Here

   * @return - JSON object with tree nodes.
   */
  private String getBookmarks(String item,String view,HttpSession session,int level,boolean paste,boolean standalone,String serviceAddr,String type)
  {
    Person viewer;
    XResource resource;
   
    boolean personEqViewer = false;
   
    //TODO: change to get person - this person exists
    viewer = PersonFactory.findPerson(view);
    if(!paste&&item!=null&&item.length()<=8)
    {
      resource = PersonFactory.findPerson(item);
      if(resource!=null)
        personEqViewer = resource.equals(viewer);
    }
    else if(type!=null&&(type.equals(S3B_SSCF.WebResource)||type.equals(S3B_SSCF.HexResource)))
    {
      resource = WebBookmarkResource.getWebBookmarkResource(item);
    }
View Full Code Here

    if(inbox!=null) {
      Iterator<XResource> it = inbox.listContent();
     
      while(it.hasNext())
      {
        XResource br = it.next();
        JSONObject jo = new JSONObject();
        jo.put("label", br.getLabel());
        jo.put("uri", br.getStringURI());
       
        ja.add(jo);
        i++;
     
    }
View Full Code Here

TOP

Related Classes of org.foafrealm.manage.XResource

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.