[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Dotgnu-pnet-commits] CVS: pnetlib/compat Vsa.cs,NONE,1.1 Makefile.am,1
From: |
Rhys Weatherley <address@hidden> |
Subject: |
[Dotgnu-pnet-commits] CVS: pnetlib/compat Vsa.cs,NONE,1.1 Makefile.am,1.1,1.2 compat.build,1.2,1.3 |
Date: |
Sun, 29 Dec 2002 20:06:25 -0500 |
Update of /cvsroot/dotgnu-pnet/pnetlib/compat
In directory subversions:/tmp/cvs-serv18056/compat
Modified Files:
Makefile.am compat.build
Added Files:
Vsa.cs
Log Message:
Implement the minor "Microsoft.Vsa" assembly, for backwards-compatibility.
--- NEW FILE ---
/*
* Vsa.cs - Scripting engine interfaces.
*
* Copyright (C) 2002 Southern Storm Software, Pty Ltd.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
[assembly:System.CLSCompliant(true)]
namespace Microsoft.Vsa
{
using System;
using System.Collections;
using System.CodeDom;
using System.Reflection;
using System.Security.Policy;
// Script item flags.
public enum VsaItemFlag
{
None = 0,
Module = 1,
Class = 2
}; // enum VsaItemFlag
// Script item types.
public enum VsaItemType
{
Reference = 0,
AppGlobal = 1,
Code = 2
}; // enum VsaItemType
// Interface for querying error information.
public interface IVsaError
{
String Description { get; }
int EndColumn { get; }
int Line { get; }
String LineText { get; }
int Number { get; }
int Severity { get; }
IVsaItem SourceItem { get; }
String SourceMoniker { get; }
int StartColumn { get; }
}; // interface IVsaError
// Interface to a script item.
public interface IVsaItem
{
bool IsDirty { get; }
VsaItemType ItemType { get; }
String Name { get; set; }
Object GetOption(String name);
void SetOption(String name, Object value);
}; // interface IVsaItem
// Collection of script items.
public interface IVsaItems : IEnumerable
{
int Count { get; }
IVsaItem this[int index] { get; }
IVsaItem this[String name] { get; }
IVsaItem CreateItem(String name, VsaItemType type, VsaItemFlag
itemFlag);
void Remove(int index);
void Remove(String name);
}; // interface IVsaItems
// Interface to a script code item.
public interface IVsaCodeItem : IVsaItem
{
#if !ECMA_COMPAT
CodeObject CodeDom { get; }
#endif
String SourceText { get; set; }
void AddEventSource(String eventSourceName, String eventSourceType);
void AppendSourceText(String text);
void RemoveEventSource(String eventSourceName);
}; // interface IVsaCodeItem
// Interface to a global script item.
public interface IVsaGlobalItem : IVsaItem
{
bool ExposeMembers { get; set; }
String TypeString { set; }
}; // interface IVsaGlobalItem
// Interface to a reference script item.
public interface IVsaReferenceItem : IVsaItem
{
String AssemblyName { get; set; }
}; // interface IVsaReferenceItem
// Interface to a site that can be used to persist script source.
public interface IVsaPersistSite
{
String LoadElement(String name);
void SaveElement(String name, String source);
}; // interface IVsaPersistSite
// Interface to a site that is used to communicate with an engine.
public interface IVsaSite
{
void GetCompiledState(out byte[] pe, out byte[] debugInfo);
Object GetEventSourceInstance(String itemName, String eventSourceName);
Object GetGlobalInstance(String name);
void Notify(String notify, Object info);
bool OnCompilerError(IVsaError error);
}; // interface IVsaSite
// Interface to a scripting engine.
public interface IVsaEngine
{
// Properties.
Assembly Assembly { get; }
Evidence Evidence { get; set; }
bool GenerateDebugInfo { get; set; }
bool IsCompiled { get; }
bool IsDirty { get; }
bool IsRunning { get; }
IVsaItems Items { get; }
String Language { get; }
int LCID { get; set; }
String Name { get; }
String RootMoniker { get; set; }
String RootNamespace { get; set; }
IVsaSite Site { get; set; }
String Version { get; }
// Methods.
void Close();
bool Compile();
Object GetOption(String name);
void InitNew();
bool IsValidIdentifier(String identifier);
void LoadSourceState(IVsaPersistSite site);
void Reset();
void RevokeCache();
void Run();
void SaveCompiledState(out byte[] pe, out byte[] pdb);
void SaveSourceState(IVsaPersistSite site);
void SetOption(String name, Object value);
}; // interface IVsaEngine
// Scripting error codes.
public enum VsaError
{
AppDomainCannotBeSet = unchecked((int)0x80133000),
AppDomainInvalid = unchecked((int)0x80133001),
ApplicationBaseCannotBeSet = unchecked((int)0x80133002),
ApplicationBaseInvalid = unchecked((int)0x80133003),
AssemblyExpected = unchecked((int)0x80133004),
AssemblyNameInvalid = unchecked((int)0x80133005),
BadAssembly = unchecked((int)0x80133006),
CachedAssemblyInvalid = unchecked((int)0x80133007),
CallbackUnexpected = unchecked((int)0x80133008),
CodeDOMNotAvailable = unchecked((int)0x80133009),
CompiledStateNotFound = unchecked((int)0x8013300A),
DebugInfoNotSupported = unchecked((int)0x8013300B),
ElementNameInvalid = unchecked((int)0x8013300C),
ElementNotFound = unchecked((int)0x8013300D),
EngineBusy = unchecked((int)0x8013300E),
EngineCannotClose = unchecked((int)0x8013300F),
EngineCannotReset = unchecked((int)0x80133010),
EngineClosed = unchecked((int)0x80133011),
EngineEmpty = unchecked((int)0x80133012),
EngineInitialized = unchecked((int)0x80133013),
EngineNameInUse = unchecked((int)0x80133014),
EngineNotCompiled = unchecked((int)0x80133015),
EngineNotInitialized = unchecked((int)0x80133016),
EngineNotRunning = unchecked((int)0x80133017),
EngineRunning = unchecked((int)0x80133018),
EventSourceInvalid = unchecked((int)0x80133019),
EventSourceNameInUse = unchecked((int)0x8013301A),
EventSourceNameInvalid = unchecked((int)0x8013301B),
EventSourceNotFound = unchecked((int)0x8013301C),
EventSourceTypeInvalid = unchecked((int)0x8013301D),
GetCompiledStateFailed = unchecked((int)0x8013301E),
GlobalInstanceInvalid = unchecked((int)0x8013301F),
GlobalInstanceTypeInvalid = unchecked((int)0x80133020),
InternalCompilerError = unchecked((int)0x80133021),
ItemCannotBeRemoved = unchecked((int)0x80133022),
ItemFlagNotSupported = unchecked((int)0x80133023),
ItemNameInUse = unchecked((int)0x80133024),
ItemNameInvalid = unchecked((int)0x80133025),
ItemNotFound = unchecked((int)0x80133026),
ItemTypeNotSupported = unchecked((int)0x80133027),
LCIDNotSupported = unchecked((int)0x80133028),
LoadElementFailed = unchecked((int)0x80133029),
NotificationInvalid = unchecked((int)0x8013302A),
OptionInvalid = unchecked((int)0x8013302B),
OptionNotSupported = unchecked((int)0x8013302C),
RevokeFailed = unchecked((int)0x8013302D),
RootMonikerAlreadySet = unchecked((int)0x8013302E),
RootMonikerInUse = unchecked((int)0x8013302F),
RootMonikerInvalid = unchecked((int)0x80133030),
RootMonikerNotSet = unchecked((int)0x80133031),
RootMonikerProtocolInvalid = unchecked((int)0x80133032),
RootNamespaceInvalid = unchecked((int)0x80133033),
RootNamespaceNotSet = unchecked((int)0x80133034),
SaveCompiledStateFailed = unchecked((int)0x80133035),
SaveElementFailed = unchecked((int)0x80133036),
SiteAlreadySet = unchecked((int)0x80133037),
SiteInvalid = unchecked((int)0x80133038),
SiteNotSet = unchecked((int)0x80133039),
SourceItemNotAvailable = unchecked((int)0x8013303A),
SourceMonikerNotAvailable = unchecked((int)0x8013303B),
URLInvalid = unchecked((int)0x8013303C),
BrowserNotExist = unchecked((int)0x8013303D),
DebuggeeNotStarted = unchecked((int)0x8013303E),
EngineNameInvalid = unchecked((int)0x8013303F),
EngineNotExist = unchecked((int)0x80133040),
FileFormatUnsupported = unchecked((int)0x80133041),
FileTypeUnknown = unchecked((int)0x80133042),
ItemCannotBeRenamed = unchecked((int)0x80133043),
MissingSource = unchecked((int)0x80133044),
NotInitCompleted = unchecked((int)0x80133045),
NameTooLong = unchecked((int)0x80133046),
ProcNameInUse = unchecked((int)0x80133047),
ProcNameInvalid = unchecked((int)0x80133048),
VsaServerDown = unchecked((int)0x80133049),
MissingPdb = unchecked((int)0x8013304A),
NotClientSideAndNoUrl = unchecked((int)0x8013304B),
CannotAttachToWebServer = unchecked((int)0x8013304C),
EngineNameNotSet = unchecked((int)0x8013304D),
UnknownError = unchecked((int)0x801330FF)
}; // enum VsaError
} // namespace Microsoft.Vsa
Index: Makefile.am
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnetlib/compat/Makefile.am,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Makefile.am 9 Dec 2002 00:17:54 -0000 1.1
--- Makefile.am 30 Dec 2002 01:06:23 -0000 1.2
***************
*** 7,11 ****
"$(CSANT)" $(CSANT_FLAGS) -f compat.build all
! CLEANFILES = Microsoft.VisualC.dll cscompmgd.dll
install-exec-local:
--- 7,11 ----
"$(CSANT)" $(CSANT_FLAGS) -f compat.build all
! CLEANFILES = Microsoft.VisualC.dll Microsoft.Vsa.dll cscompmgd.dll
install-exec-local:
***************
*** 13,16 ****
--- 13,17 ----
$(mkinstalldirs) $(DESTDIR)$(libdir)/cscc/lib
$(INSTALL_DATA) Microsoft.VisualC.dll
$(DESTDIR)$(libdir)/cscc/lib/Microsoft.VisualC.dll
+ $(INSTALL_DATA) Microsoft.Vsa.dll
$(DESTDIR)$(libdir)/cscc/lib/Microsoft.Vsa.dll
$(INSTALL_DATA) cscompmgd.dll $(DESTDIR)$(libdir)/cscc/lib/cscompmgd.dll
***************
*** 18,20 ****
--- 19,22 ----
@$(NORMALL_UNINSTALL)
rm -f $(DESTDIR)$(libdir)/cscc/lib/Microsoft.VisualC.dll
+ rm -f $(DESTDIR)$(libdir)/cscc/lib/Microsoft.Vsa.dll
rm -f $(DESTDIR)$(libdir)/cscc/lib/cscompmgd.dll
Index: compat.build
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnetlib/compat/compat.build,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** compat.build 9 Dec 2002 01:04:01 -0000 1.2
--- compat.build 30 Dec 2002 01:06:23 -0000 1.3
***************
*** 52,55 ****
--- 52,80 ----
</compile>
+ <!-- Build the Microsoft.Vsa.dll library -->
+ <compile output="Microsoft.Vsa.dll"
+ target="library"
+ unsafe="true"
+ nostdlib="true"
+ optimize="true"
+ debug="true">
+
+ <sources>
+ <file name="Vsa.cs"/>
+ </sources>
+
+ <references>
+ <file name="../System/System.dll"/>
+ <file name="../runtime/mscorlib.dll"/>
+ </references>
+
+ <arg compiler="cscc" value="-Wno-empty-input"/>
+ <arg compiler="csc" value="/nowarn:626"/>
+ <arg compiler="csc" value="/nowarn:649"/>
+ <arg compiler="csc" value="/nowarn:168"/>
+ <arg compiler="csc" value="/nowarn:67"/>
+ <arg compiler="csc" value="/nowarn:169"/>
+ </compile>
+
</target>
</project>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Dotgnu-pnet-commits] CVS: pnetlib/compat Vsa.cs,NONE,1.1 Makefile.am,1.1,1.2 compat.build,1.2,1.3,
Rhys Weatherley <address@hidden> <=
- Prev by Date:
[Dotgnu-pnet-commits] CVS: pnet ChangeLog,1.2033,1.2034 Makefile.am,1.19,1.20
- Next by Date:
[Dotgnu-pnet-commits] CVS: pnetlib ChangeLog,1.588,1.589
- Previous by thread:
[Dotgnu-pnet-commits] CVS: pnet ChangeLog,1.2033,1.2034 Makefile.am,1.19,1.20
- Next by thread:
[Dotgnu-pnet-commits] CVS: pnetlib ChangeLog,1.588,1.589
- Index(es):