Project

General

Profile

« Previous | Next » 

Revision 1435

Added by Jing Tao almost 22 years ago

Fixed a bug that access control couldn't write into db.

View differences:

src/edu/ucsb/nceas/metacat/DocumentImpl.java
751 751
    return rev;
752 752
  }
753 753
  
754
   /**
754
  /**
755 755
   * Print a string representation of the XML document
756 756
   */
757 757
  public String toString(String user, String[] groups)
758 758
  {
759 759
    StringWriter docwriter = new StringWriter();
760
    try {
760
    try 
761
    {
761 762
      this.toXml(docwriter, user, groups);
762
    } catch (McdbException mcdbe) {
763
    } 
764
    catch (McdbException mcdbe) 
765
    {
763 766
      return null;
764 767
    }
765 768
    String document = docwriter.toString();
766 769
    return document;
767 770
  }
771
  
772
   /**
773
   * Print a string representation of the XML document
774
   */
775
  public String toString()
776
  {
777
    StringWriter docwriter = new StringWriter();
778
    String userName = null;
779
    String[] groupNames = null;
780
    try 
781
    {
782
      this.toXml(docwriter, userName, groupNames);
783
    } 
784
    catch (McdbException mcdbe) 
785
    {
786
      return null;
787
    }
788
    String document = docwriter.toString();
789
    return document;
790
  }
768 791

  
769 792
  /**
770 793
   * Get a text representation of the XML document as a string

Also available in: Unified diff