/// <summary> /// This constructor is used when we have just the name and it is an email /// </summary> public Document( string name ) { if (name == null) { System.Diagnostics.Trace.WriteLine( Workshare.Reports.Properties.Resources.TRACE_NULL, "Document" ); throw ( new ArgumentNullException( "name", Workshare.Reports.Properties.Resources.TRACE_NULL ) ); } m_name = name; m_policies = new PolicySetCollection(); m_content = ContentType.Email; }
/// <summary> /// This constructor is used when we have just the name /// </summary> public Document( Guid messageId, string name, string content, string source, string displayName, long size, bool isEncrypted ) { if (source == null) source = ""; if (name == null || source == null || displayName == null || content == null) { System.Diagnostics.Trace.WriteLine( Workshare.Reports.Properties.Resources.TRACE_NULL, "Document" ); throw ( new ArgumentNullException( "name, source, displayName, content", Workshare.Reports.Properties.Resources.TRACE_NULL ) ); } m_msgId = messageId; m_name = name; m_source = source; m_display = displayName; m_size = size; m_isEncrypted = isEncrypted; WorkoutType( content ); m_policies = new PolicySetCollection(); }
/// <summary> /// This constructor will create an empty class, normally /// used when the Node property is assigned /// </summary> public Document(Guid id) { m_policies = new PolicySetCollection(); m_content = ContentType.Email; m_msgId = id; }