Logo Search packages:      
Sourcecode: f-spot version File versions

GeoPermissions.cs

using System;
using System.Xml;

namespace FlickrNet
{
      /// <summary>
      /// Permissions for the selected photo.
      /// </summary>
      [System.Serializable]
00010       public class GeoPermissions
      {
            private string _photoId;
            private bool _isPublic;
            private bool _isContact;
            private bool _isFriend;
            private bool _isFamily;

            internal GeoPermissions(XmlElement element)
            {
                  if( element.Attributes.GetNamedItem("id") != null )
                        _photoId = element.Attributes.GetNamedItem("id").Value;
                  if( element.Attributes.GetNamedItem("ispublic") != null )
                        _isPublic = element.Attributes.GetNamedItem("ispublic").Value=="1";
                  if( element.Attributes.GetNamedItem("iscontact") != null )
                        _isContact = element.Attributes.GetNamedItem("iscontact").Value=="1";
                  if( element.Attributes.GetNamedItem("isfamily") != null )
                        _isFamily = element.Attributes.GetNamedItem("isfamily").Value=="1";
                  if( element.Attributes.GetNamedItem("isfriend") != null )
                        _isFriend = element.Attributes.GetNamedItem("isfriend").Value=="1";
            }

            /// <summary>
            /// The ID for the photo whose permissions these are.
            /// </summary>
            public string PhotoId
00036             {
                  get { return _photoId; }
            }

            /// <summary>
            /// Are the general unwashed (public) allowed to see the Geo Location information for this photo.
            /// </summary>
            public bool IsPublic
00044             {
                  get { return _isPublic; }
            }
    
            /// <summary>
            /// Are contacts allowed to see the Geo Location information for this photo.
            /// </summary>
            public bool IsContact
00052             {
                  get { return _isContact; }
            }
    
            /// <summary>
            /// Are friends allowed to see the Geo Location information for this photo.
            /// </summary>
            public bool IsFriend
00060             {
                  get { return _isFriend; }
            }
    
            /// <summary>
            /// Are family allowed to see the Geo Location information for this photo.
            /// </summary>
            public bool IsFamily
00068             {
                  get { return _isFamily; }
            }

      }
}

Generated by  Doxygen 1.6.0   Back to index