You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by bo...@apache.org on 2018/06/01 13:36:25 UTC

[1/2] logging-log4net git commit: version is never used

Repository: logging-log4net
Updated Branches:
  refs/heads/feature/LOG4NET-586 cc8a05758 -> 9dc492647


version is never used


Project: http://git-wip-us.apache.org/repos/asf/logging-log4net/repo
Commit: http://git-wip-us.apache.org/repos/asf/logging-log4net/commit/a8925fcd
Tree: http://git-wip-us.apache.org/repos/asf/logging-log4net/tree/a8925fcd
Diff: http://git-wip-us.apache.org/repos/asf/logging-log4net/diff/a8925fcd

Branch: refs/heads/feature/LOG4NET-586
Commit: a8925fcd6fc2f1ef33db8f62f0253a17f8386638
Parents: cc8a057
Author: Stefan Bodewig <bo...@apache.org>
Authored: Fri Jun 1 15:29:55 2018 +0200
Committer: Stefan Bodewig <bo...@apache.org>
Committed: Fri Jun 1 15:29:55 2018 +0200

----------------------------------------------------------------------
 src/Layout/XmlLayoutSchemaLog4jNS.cs | 20 --------------------
 1 file changed, 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/logging-log4net/blob/a8925fcd/src/Layout/XmlLayoutSchemaLog4jNS.cs
----------------------------------------------------------------------
diff --git a/src/Layout/XmlLayoutSchemaLog4jNS.cs b/src/Layout/XmlLayoutSchemaLog4jNS.cs
index aa7c33b..96f35f2 100644
--- a/src/Layout/XmlLayoutSchemaLog4jNS.cs
+++ b/src/Layout/XmlLayoutSchemaLog4jNS.cs
@@ -85,26 +85,6 @@ namespace log4net.Layout
 		#region Public Properties
 
 		/// <summary>
-		/// The version of the log4j schema to use.
-		/// </summary>
-		/// <remarks>
-		/// <para>
-		/// Only version 1.2 of the log4j schema is supported.
-		/// </para>
-		/// </remarks>
-		public string Version
-		{
-			get { return "1.2"; }
-			set
-			{
-				if (value != "1.2")
-				{
-					throw new ArgumentException("Only version 1.2 of the log4j schema is currently supported");
-				}
-			}
-		}
-
-		/// <summary>
 		/// The namespace URI to use for the elements and attributes written by this layout.
 		/// </summary>
 		/// <remarks>


[2/2] logging-log4net git commit: LOG4NET-586 de-virtualize Namespace and Prefix properties

Posted by bo...@apache.org.
LOG4NET-586 de-virtualize Namespace and Prefix properties


Project: http://git-wip-us.apache.org/repos/asf/logging-log4net/repo
Commit: http://git-wip-us.apache.org/repos/asf/logging-log4net/commit/9dc49264
Tree: http://git-wip-us.apache.org/repos/asf/logging-log4net/tree/9dc49264
Diff: http://git-wip-us.apache.org/repos/asf/logging-log4net/diff/9dc49264

Branch: refs/heads/feature/LOG4NET-586
Commit: 9dc49264761f575709a03bce16c4cac2f2f09c2d
Parents: a8925fc
Author: Stefan Bodewig <bo...@apache.org>
Authored: Fri Jun 1 15:35:49 2018 +0200
Committer: Stefan Bodewig <bo...@apache.org>
Committed: Fri Jun 1 15:35:49 2018 +0200

----------------------------------------------------------------------
 src/Layout/XmlLayoutBaseNS.cs        |  4 ++--
 src/Layout/XmlLayoutSchemaLog4jNS.cs | 33 +++----------------------------
 2 files changed, 5 insertions(+), 32 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/logging-log4net/blob/9dc49264/src/Layout/XmlLayoutBaseNS.cs
----------------------------------------------------------------------
diff --git a/src/Layout/XmlLayoutBaseNS.cs b/src/Layout/XmlLayoutBaseNS.cs
index c3e1f5b..c4fe537 100644
--- a/src/Layout/XmlLayoutBaseNS.cs
+++ b/src/Layout/XmlLayoutBaseNS.cs
@@ -131,7 +131,7 @@ namespace log4net.Layout
 		/// <summary>
 		/// The namespace URI to use for the elements and attributes written by this layout.
 		/// </summary>
-		public virtual string NamespaceUri
+		public string NamespaceUri
 		{
 			get { return m_namespaceUri; }
 			set { m_namespaceUri = value; }
@@ -146,7 +146,7 @@ namespace log4net.Layout
 		/// select the prefix or use no prefix at all.
 		/// </para>
 		/// </remarks>
-		public virtual string Prefix
+		public string Prefix
 		{
 			get { return m_prefix; }
 			set { m_prefix = value; }

http://git-wip-us.apache.org/repos/asf/logging-log4net/blob/9dc49264/src/Layout/XmlLayoutSchemaLog4jNS.cs
----------------------------------------------------------------------
diff --git a/src/Layout/XmlLayoutSchemaLog4jNS.cs b/src/Layout/XmlLayoutSchemaLog4jNS.cs
index 96f35f2..bb725d7 100644
--- a/src/Layout/XmlLayoutSchemaLog4jNS.cs
+++ b/src/Layout/XmlLayoutSchemaLog4jNS.cs
@@ -55,7 +55,7 @@ namespace log4net.Layout
 		/// <summary>
 		/// Constructs an XMLLayoutSchemaLog4jNS
 		/// </summary>
-		public XmlLayoutSchemaLog4jNS() : base()
+		public XmlLayoutSchemaLog4jNS() : this(false)
 		{
 		}
 
@@ -78,39 +78,12 @@ namespace log4net.Layout
 		/// </remarks>
 		public XmlLayoutSchemaLog4jNS(bool locationInfo) :  base(locationInfo)
 		{
+			Namespace = LOG4J_SCHEMA;
+			Prefix = LOG4J_PREFIX;
 		}
 
 		#endregion
 
-		#region Public Properties
-
-		/// <summary>
-		/// The namespace URI to use for the elements and attributes written by this layout.
-		/// </summary>
-		/// <remarks>
-		/// <para>
-		/// Unless configured explicitly http://logging.apache.org/log4j is used.
-		/// </para>
-		/// </remarks>
-		public override string NamespaceUri
-		{
-			get { return base.NamespaceUri == null ? LOG4J_SCHEMA : base.NamespaceUri; }
-		}
-
-		/// <summary>
-		/// The prefix to use for the elements and attributes written by this layout.
-		/// </summary>
-		/// <remarks>
-		/// <para>
-		/// Unless configured explicitly log4j is used.
-		/// </para>
-		/// </remarks>
-		public override string Prefix
-		{
-			get { return base.Prefix == null ? LOG4J_PREFIX : base.Prefix; }
-		}
-		#endregion
-
 		/* Example log4j schema event
 
 <log4j:event logger="first logger" level="ERROR" thread="Thread-3" timestamp="1051494121460" xmlns:log4j="http://logging.apache.org/log4j">