diff options
author | Paolo Molaro <lupus@oddwiz.org> | 2003-07-18 18:03:07 +0400 |
---|---|---|
committer | Paolo Molaro <lupus@oddwiz.org> | 2003-07-18 18:03:07 +0400 |
commit | dd1dded085e18612909416f0e7053fa0ea468090 (patch) | |
tree | f444f9fdf7b85aab8b17d738d56442820b0b3388 | |
parent | 0e80b16392eee6efb99499fa2d31eb3b91d25da0 (diff) |
Do not expose the classes when they are compiled inside corlib as helpers.
svn path=/trunk/mcs/; revision=16404
20 files changed, 128 insertions, 23 deletions
diff --git a/mcs/class/corlib/Makefile b/mcs/class/corlib/Makefile index 949b6e1e85b..8ef5971103b 100644 --- a/mcs/class/corlib/Makefile +++ b/mcs/class/corlib/Makefile @@ -21,7 +21,7 @@ sourcefile = corlib.dll.sources response = $(depsdir)/corlib.dll.response makefrag = $(depsdir)/corlib.dll.makefrag stampfile = $(depsdir)/corlib.dll.stamp -corlib_flags = /unsafe /nostdlib +corlib_flags = /unsafe /nostdlib /d:INSIDE_CORLIB test_sourcefile = corlib_test.dll.sources test_response = $(depsdir)/$(testlib).response diff --git a/mcs/class/corlib/Mono.Math.Prime.Generator/NextPrimeFinder.cs b/mcs/class/corlib/Mono.Math.Prime.Generator/NextPrimeFinder.cs index 54e4df687c7..a5fdd9aa599 100644 --- a/mcs/class/corlib/Mono.Math.Prime.Generator/NextPrimeFinder.cs +++ b/mcs/class/corlib/Mono.Math.Prime.Generator/NextPrimeFinder.cs @@ -15,7 +15,12 @@ namespace Mono.Math.Prime.Generator { /// Finds the next prime after a given number. /// </summary> [CLSCompliant(false)] - public class NextPrimeFinder : SequentialSearchPrimeGeneratorBase { +#if INSIDE_CORLIB + internal +#else + public +#endif + class NextPrimeFinder : SequentialSearchPrimeGeneratorBase { protected override BigInteger GenerateSearchBase (int bits, object Context) { diff --git a/mcs/class/corlib/Mono.Math.Prime.Generator/PrimeGeneratorBase.cs b/mcs/class/corlib/Mono.Math.Prime.Generator/PrimeGeneratorBase.cs index 523f537dcc5..8bf6b2f3262 100644 --- a/mcs/class/corlib/Mono.Math.Prime.Generator/PrimeGeneratorBase.cs +++ b/mcs/class/corlib/Mono.Math.Prime.Generator/PrimeGeneratorBase.cs @@ -12,7 +12,12 @@ using System; namespace Mono.Math.Prime.Generator { [CLSCompliant(false)] - public abstract class PrimeGeneratorBase { +#if INSIDE_CORLIB + internal +#else + public +#endif + abstract class PrimeGeneratorBase { public virtual ConfidenceFactor Confidence { get { diff --git a/mcs/class/corlib/Mono.Math.Prime.Generator/SequentialSearchPrimeGeneratorBase.cs b/mcs/class/corlib/Mono.Math.Prime.Generator/SequentialSearchPrimeGeneratorBase.cs index 2d6466492da..ec165556941 100644 --- a/mcs/class/corlib/Mono.Math.Prime.Generator/SequentialSearchPrimeGeneratorBase.cs +++ b/mcs/class/corlib/Mono.Math.Prime.Generator/SequentialSearchPrimeGeneratorBase.cs @@ -13,7 +13,12 @@ using Mono.Math.Prime; namespace Mono.Math.Prime.Generator { [CLSCompliant(false)] - public class SequentialSearchPrimeGeneratorBase : PrimeGeneratorBase { +#if INSIDE_CORLIB + internal +#else + public +#endif + class SequentialSearchPrimeGeneratorBase : PrimeGeneratorBase { protected virtual BigInteger GenerateSearchBase (int bits, object Context) { diff --git a/mcs/class/corlib/Mono.Math.Prime/ConfidenceFactor.cs b/mcs/class/corlib/Mono.Math.Prime/ConfidenceFactor.cs index 1f93e7872eb..7db11eebd79 100644 --- a/mcs/class/corlib/Mono.Math.Prime/ConfidenceFactor.cs +++ b/mcs/class/corlib/Mono.Math.Prime/ConfidenceFactor.cs @@ -13,7 +13,12 @@ namespace Mono.Math.Prime { /// <summary> /// A factor of confidence. /// </summary> - public enum ConfidenceFactor { +#if INSIDE_CORLIB + internal +#else + public +#endif + enum ConfidenceFactor { /// <summary> /// Only suitable for development use, probability of failure may be greater than 1/2^20. /// </summary> diff --git a/mcs/class/corlib/Mono.Math.Prime/PrimalityTests.cs b/mcs/class/corlib/Mono.Math.Prime/PrimalityTests.cs index e6ae8c7124f..9b1d1fa5f66 100644 --- a/mcs/class/corlib/Mono.Math.Prime/PrimalityTests.cs +++ b/mcs/class/corlib/Mono.Math.Prime/PrimalityTests.cs @@ -13,10 +13,20 @@ using System.Security.Cryptography; namespace Mono.Math.Prime { [CLSCompliant(false)] - public delegate bool PrimalityTest (BigInteger bi, ConfidenceFactor confidence); +#if INSIDE_CORLIB + internal +#else + public +#endif + delegate bool PrimalityTest (BigInteger bi, ConfidenceFactor confidence); [CLSCompliant(false)] - public sealed class PrimalityTests { +#if INSIDE_CORLIB + internal +#else + public +#endif + sealed class PrimalityTests { #region SPP Test diff --git a/mcs/class/corlib/Mono.Math/BigInteger.cs b/mcs/class/corlib/Mono.Math/BigInteger.cs index 28f37a9ce62..864c3af2034 100644 --- a/mcs/class/corlib/Mono.Math/BigInteger.cs +++ b/mcs/class/corlib/Mono.Math/BigInteger.cs @@ -20,7 +20,12 @@ using Mono.Math.Prime; namespace Mono.Math { [CLSCompliant(false)] - public class BigInteger { +#if INSIDE_CORLIB + internal +#else + public +#endif + class BigInteger { #region Data Storage diff --git a/mcs/class/corlib/Mono.Security.Cryptography/CryptoTools.cs b/mcs/class/corlib/Mono.Security.Cryptography/CryptoTools.cs index 50b1e9b0478..111b875728c 100644 --- a/mcs/class/corlib/Mono.Security.Cryptography/CryptoTools.cs +++ b/mcs/class/corlib/Mono.Security.Cryptography/CryptoTools.cs @@ -13,7 +13,12 @@ using System.Security.Cryptography; namespace Mono.Security.Cryptography { - public class KeyBuilder { +#if INSIDE_CORLIB + internal +#else + public +#endif + class KeyBuilder { static private RandomNumberGenerator rng; @@ -38,7 +43,12 @@ namespace Mono.Security.Cryptography { } // Process an array as a sequence of blocks - public class BlockProcessor { +#if INSIDE_CORLIB + internal +#else + public +#endif + class BlockProcessor { private ICryptoTransform transform; private byte[] block; private int blockSize; // in bytes (not in bits) diff --git a/mcs/class/corlib/Mono.Security.Cryptography/DSAManaged.cs b/mcs/class/corlib/Mono.Security.Cryptography/DSAManaged.cs index 5d69107b8f6..8852f6f9f9f 100644 --- a/mcs/class/corlib/Mono.Security.Cryptography/DSAManaged.cs +++ b/mcs/class/corlib/Mono.Security.Cryptography/DSAManaged.cs @@ -20,7 +20,12 @@ using Mono.Math; namespace Mono.Security.Cryptography { - public class DSAManaged : DSA { +#if INSIDE_CORLIB + internal +#else + public +#endif + class DSAManaged : DSA { private const int defaultKeySize = 1024; diff --git a/mcs/class/corlib/Mono.Security.Cryptography/PKCS1.cs b/mcs/class/corlib/Mono.Security.Cryptography/PKCS1.cs index be8a1523152..a5610b6f2d3 100644 --- a/mcs/class/corlib/Mono.Security.Cryptography/PKCS1.cs +++ b/mcs/class/corlib/Mono.Security.Cryptography/PKCS1.cs @@ -16,7 +16,12 @@ namespace Mono.Security.Cryptography { // a. PKCS#1: RSA Cryptography Standard // http://www.rsasecurity.com/rsalabs/pkcs/pkcs-1/index.html - public class PKCS1 { +#if INSIDE_CORLIB + internal +#else + public +#endif + class PKCS1 { private static bool Compare (byte[] array1, byte[] array2) { diff --git a/mcs/class/corlib/Mono.Security.Cryptography/RSAManaged.cs b/mcs/class/corlib/Mono.Security.Cryptography/RSAManaged.cs index 1c8d9a65883..2338da5def4 100644 --- a/mcs/class/corlib/Mono.Security.Cryptography/RSAManaged.cs +++ b/mcs/class/corlib/Mono.Security.Cryptography/RSAManaged.cs @@ -27,7 +27,12 @@ using Mono.Math; namespace Mono.Security.Cryptography { - public class RSAManaged : RSA { +#if INSIDE_CORLIB + internal +#else + public +#endif + class RSAManaged : RSA { private const int defaultKeySize = 1024; diff --git a/mcs/class/corlib/Mono.Security.X509/X501Name.cs b/mcs/class/corlib/Mono.Security.X509/X501Name.cs index d5f55604718..a5de173b388 100644 --- a/mcs/class/corlib/Mono.Security.X509/X501Name.cs +++ b/mcs/class/corlib/Mono.Security.X509/X501Name.cs @@ -27,7 +27,12 @@ namespace Mono.Security.X509 { * * RelativeDistinguishedName ::= SET OF AttributeTypeAndValue */ - public class X501 { +#if INSIDE_CORLIB + internal +#else + public +#endif + class X501 { static byte[] countryName = { 0x55, 0x04, 0x06 }; static byte[] organizationName = { 0x55, 0x04, 0x0A }; diff --git a/mcs/class/corlib/Mono.Security.X509/X509Certificate.cs b/mcs/class/corlib/Mono.Security.X509/X509Certificate.cs index e0884e04cb1..142ead32125 100644 --- a/mcs/class/corlib/Mono.Security.X509/X509Certificate.cs +++ b/mcs/class/corlib/Mono.Security.X509/X509Certificate.cs @@ -20,7 +20,12 @@ namespace Mono.Security.X509 { // b. ITU ASN.1 standards (free download) // http://www.itu.int/ITU-T/studygroups/com17/languages/ - public class X509Certificate { +#if INSIDE_CORLIB + internal +#else + public +#endif + class X509Certificate { private ASN1 decoder; @@ -429,4 +434,4 @@ namespace Mono.Security.X509 { } } } -}
\ No newline at end of file +} diff --git a/mcs/class/corlib/Mono.Security.X509/X509Extension.cs b/mcs/class/corlib/Mono.Security.X509/X509Extension.cs index 353ad31beb8..7e23aa3cefc 100644 --- a/mcs/class/corlib/Mono.Security.X509/X509Extension.cs +++ b/mcs/class/corlib/Mono.Security.X509/X509Extension.cs @@ -20,7 +20,12 @@ namespace Mono.Security.X509 { * extnValue OCTET STRING * } */ - public class X509Extension { +#if INSIDE_CORLIB + internal +#else + public +#endif + class X509Extension { protected string extnOid; protected bool extnCritical; diff --git a/mcs/class/corlib/Mono.Security.X509/X509Extensions.cs b/mcs/class/corlib/Mono.Security.X509/X509Extensions.cs index 488ceed8725..3397d468767 100644 --- a/mcs/class/corlib/Mono.Security.X509/X509Extensions.cs +++ b/mcs/class/corlib/Mono.Security.X509/X509Extensions.cs @@ -18,7 +18,12 @@ namespace Mono.Security.X509 { * * Note: 1..MAX -> There shouldn't be 0 Extensions in the ASN1 structure */ - public class X509Extensions : ICollection, IEnumerable { +#if INSIDE_CORLIB + internal +#else + public +#endif + class X509Extensions : ICollection, IEnumerable { private ArrayList extensions; private bool readOnly; diff --git a/mcs/class/corlib/Mono.Security.X509/X520Attributes.cs b/mcs/class/corlib/Mono.Security.X509/X520Attributes.cs index 98cd3ebf1ce..f8806ec9eba 100644 --- a/mcs/class/corlib/Mono.Security.X509/X520Attributes.cs +++ b/mcs/class/corlib/Mono.Security.X509/X520Attributes.cs @@ -30,7 +30,12 @@ namespace Mono.Security.X509 { * * AttributeValue ::= ANY DEFINED BY AttributeType */ - public class X520 { +#if INSIDE_CORLIB + internal +#else + public +#endif + class X520 { public abstract class AttributeTypeAndValue { protected string oid; diff --git a/mcs/class/corlib/Mono.Security/ASN1.cs b/mcs/class/corlib/Mono.Security/ASN1.cs index 36e493f23cc..79f9d8464e5 100644 --- a/mcs/class/corlib/Mono.Security/ASN1.cs +++ b/mcs/class/corlib/Mono.Security/ASN1.cs @@ -16,7 +16,12 @@ namespace Mono.Security { // a. ITU ASN.1 standards (free download) // http://www.itu.int/ITU-T/studygroups/com17/languages/ -public class ASN1 { +#if INSIDE_CORLIB + internal +#else + public +#endif +class ASN1 { protected byte m_nTag; protected byte[] m_aValue; diff --git a/mcs/class/corlib/Mono.Security/ASN1Convert.cs b/mcs/class/corlib/Mono.Security/ASN1Convert.cs index b00b8006ab5..af8127cc5ed 100644 --- a/mcs/class/corlib/Mono.Security/ASN1Convert.cs +++ b/mcs/class/corlib/Mono.Security/ASN1Convert.cs @@ -18,7 +18,12 @@ namespace Mono.Security { // a. ITU ASN.1 standards (free download) // http://www.itu.int/ITU-T/studygroups/com17/languages/ - public class ASN1Convert { +#if INSIDE_CORLIB + internal +#else + public +#endif + class ASN1Convert { // RFC3280, section 4.2.1.5 // CAs conforming to this profile MUST always encode certificate diff --git a/mcs/class/corlib/Mono.Xml/MiniParser.cs b/mcs/class/corlib/Mono.Xml/MiniParser.cs index 97f973ea3af..55332dccb35 100644 --- a/mcs/class/corlib/Mono.Xml/MiniParser.cs +++ b/mcs/class/corlib/Mono.Xml/MiniParser.cs @@ -37,7 +37,12 @@ using System.Globalization; namespace Mono.Xml { [CLSCompliant(false)] -public class MiniParser { +#if INSIDE_CORLIB + internal +#else + public +#endif +class MiniParser { public interface IReader { int Read(); diff --git a/mcs/class/corlib/Mono.Xml/SecurityParser.cs b/mcs/class/corlib/Mono.Xml/SecurityParser.cs index 421cdb2a8a1..6c0d9659125 100644 --- a/mcs/class/corlib/Mono.Xml/SecurityParser.cs +++ b/mcs/class/corlib/Mono.Xml/SecurityParser.cs @@ -15,7 +15,12 @@ namespace Mono.Xml { // convert an XML document into SecurityElement objects [CLSCompliant(false)] - public class SecurityParser : MiniParser, MiniParser.IHandler, MiniParser.IReader { +#if INSIDE_CORLIB + internal +#else + public +#endif + class SecurityParser : MiniParser, MiniParser.IHandler, MiniParser.IReader { private SecurityElement root; |