Skip to main content

ProtectedScripts

Assembly: ServiceStack.Common.dll
View Source
Declaration
public class ProtectedScripts : ScriptMethods

Inherited Properties

Context

View Source
Declaration
public ScriptContext Context { get; set; }

InvokerCache

View Source
Declaration
public ConcurrentDictionary<string, MethodInvoker> InvokerCache { get; }

Pages

View Source
Declaration
public ISharpPages Pages { get; set; }

Fields

Instance

View Source
Declaration
public static readonly ProtectedScripts Instance

Methods

resolve(ScriptScopeContext, Object)

View Source
Declaration
public object resolve(ScriptScopeContext scope, object type)
Returns

System.Object

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Objecttype

default(String)

View Source
Declaration
public object default(string typeName)
Returns

System.Object

Parameters
TypeName
System.StringtypeName

new(String)

View Source
Declaration
public object new(string typeName)
Returns

System.Object

Parameters
TypeName
System.StringtypeName

new(String, List<Object>)

View Source
Declaration
public object new(string typeName, List<object> constructorArgs)
Returns

System.Object

Parameters
TypeName
System.StringtypeName
System.Collections.Generic.List<System.Object>constructorArgs

set(Object, Dictionary<String, Object>)

View Source
Declaration
public object set(object instance, Dictionary<string, object> args)
Returns

System.Object

Parameters
TypeName
System.Objectinstance
System.Collections.Generic.Dictionary<System.String,System.Object>args

createInstance(Type)

View Source
Declaration
public object createInstance(Type type)
Returns

System.Object

Parameters
TypeName
System.Typetype

createInstance(Type, List<Object>)

View Source
Declaration
public object createInstance(Type type, List<object> constructorArgs)
Returns

System.Object

Parameters
TypeName
System.Typetype
System.Collections.Generic.List<System.Object>constructorArgs

getType(Object)

View Source
Declaration
public Type getType(object instance)
Returns

System.Type

Parameters
TypeName
System.Objectinstance

typeQualifiedName(Type)

View Source
Declaration
public string typeQualifiedName(Type type)
Returns

System.String

Parameters
TypeName
System.Typetype

TypeNotFoundErrorMessage(String)

View Source
Declaration
public static string TypeNotFoundErrorMessage(string typeName)
Returns

System.String

Parameters
TypeName
System.StringtypeName

assertTypeOf(String)

View Source
Declaration
public Type assertTypeOf(string name)
Returns

System.Type

Parameters
TypeName
System.Stringname

typeof(String)

Returns Type from type name syntax of .NET's typeof()

View Source
Declaration
public Type typeof(string typeName)
Returns

System.Type

Parameters
TypeName
System.StringtypeName

typeofProgId(String)

View Source
Declaration
public Type typeofProgId(string name)
Returns

System.Type

Parameters
TypeName
System.Stringname

call(Object, String)

View Source
Declaration
public object call(object instance, string name)
Returns

System.Object

Parameters
TypeName
System.Objectinstance
System.Stringname

call(Object, String, List<Object>)

View Source
Declaration
public object call(object instance, string name, List<object> args)
Returns

System.Object

Parameters
TypeName
System.Objectinstance
System.Stringname
System.Collections.Generic.List<System.Object>args

Constructor(String)

Qualified Constructor Name Examples:

  • Type()
  • Type(string)
  • GenericType<string<(System.Int32)
  • Namespace.Type()
View Source
Declaration
public ObjectActivator Constructor(string qualifiedConstructorName)
Returns

ServiceStack.ObjectActivator

Parameters
TypeName
System.StringqualifiedConstructorName

C(String)

Shorter Alias for Constructor

View Source
Declaration
public Delegate C(string qualifiedMethodName)
Returns

System.Delegate

Parameters
TypeName
System.StringqualifiedMethodName

F(String)

Shorter Alias for Function

View Source
Declaration
public Delegate F(string qualifiedMethodName)
Returns

System.Delegate

Parameters
TypeName
System.StringqualifiedMethodName

F(String, List<Object>)

Shorter Alias for Function(name,args)

View Source
Declaration
public Delegate F(string qualifiedMethodName, List<object> args)
Returns

System.Delegate

Parameters
TypeName
System.StringqualifiedMethodName
System.Collections.Generic.List<System.Object>args

Function(String)

Qualified Method Name Examples:

  • Console.WriteLine(string)
  • Type.StaticMethod
  • Type.InstanceMethod
  • GenericType<string<.Method
  • GenericType<string<.GenericMethod<System.Int32<
  • Namespace.Type.Method
View Source
Declaration
public Delegate Function(string qualifiedMethodName)
Returns

System.Delegate

Parameters
TypeName
System.StringqualifiedMethodName

Function(String, List<Object>)

Resolve Function from qualified type name, when args Type list are unspecified fallback to use args to resolve ambiguous methods

Qualified Method Name Examples:

  • Console.WriteLine ['string']
  • Type.StaticMethod
  • Type.InstanceMethod
  • GenericType<string<.Method
  • GenericType<string<.GenericMethod<System.Int32<
  • Namespace.Type.Method
View Source
Declaration
public Delegate Function(string qualifiedMethodName, List<object> args)
Returns

System.Delegate

Parameters
TypeName
System.StringqualifiedMethodName
System.Collections.Generic.List<System.Object>args

vfsMemory()

View Source
Declaration
public MemoryVirtualFiles vfsMemory()
Returns

ServiceStack.IO.MemoryVirtualFiles

vfsFileSystem(String)

View Source
Declaration
public FileSystemVirtualFiles vfsFileSystem(string dirPath)
Returns

ServiceStack.IO.FileSystemVirtualFiles

Parameters
TypeName
System.StringdirPath

vfsGist(String)

View Source
Declaration
public GistVirtualFiles vfsGist(string gistId)
Returns

ServiceStack.IO.GistVirtualFiles

Parameters
TypeName
System.StringgistId

vfsGist(String, String)

View Source
Declaration
public GistVirtualFiles vfsGist(string gistId, string accessToken)
Returns

ServiceStack.IO.GistVirtualFiles

Parameters
TypeName
System.StringgistId
System.StringaccessToken

osPaths(String)

View Source
Declaration
public string osPaths(string path)
Returns

System.String

Parameters
TypeName
System.Stringpath

resolveFile(ScriptScopeContext, String)

View Source
Declaration
public IVirtualFile resolveFile(ScriptScopeContext scope, string virtualPath)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath

ResolveFile(String, ScriptScopeContext, String)

View Source
Declaration
public IVirtualFile ResolveFile(string filterName, ScriptScopeContext scope, string virtualPath)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
System.StringfilterName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath

ResolveFile(IVirtualPathProvider, String, String)

View Source
Declaration
public IVirtualFile ResolveFile(IVirtualPathProvider virtualFiles, string fromVirtualPath, string virtualPath)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervirtualFiles
System.StringfromVirtualPath
System.StringvirtualPath

includeFile(ScriptScopeContext, String)

View Source
Declaration
public async Task includeFile(ScriptScopeContext scope, string virtualPath)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath

ifDebugIncludeScript(ScriptScopeContext, String)

View Source
Declaration
public async Task ifDebugIncludeScript(ScriptScopeContext scope, string virtualPath)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath

vfsAllFiles()

View Source
Declaration
[Alias("allFiles")]
public IEnumerable<IVirtualFile> vfsAllFiles()
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

vfsAllRootFiles()

View Source
Declaration
[Alias("allRootFiles")]
public IEnumerable<IVirtualFile> vfsAllRootFiles()
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

vfsAllRootDirectories()

View Source
Declaration
[Alias("allRootDirectories")]
public IEnumerable<IVirtualDirectory> vfsAllRootDirectories()
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualDirectory>

vfsCombinePath(String, String)

View Source
Declaration
[Alias("combinePath")]
public string vfsCombinePath(string basePath, string relativePath)
Returns

System.String

Parameters
TypeName
System.StringbasePath
System.StringrelativePath

dirFilesFind(String, String)

View Source
Declaration
[Alias("findFilesInDirectory")]
public IEnumerable<IVirtualFile> dirFilesFind(string dirPath, string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
System.StringdirPath
System.StringglobPattern

filesFind(String)

View Source
Declaration
[Alias("findFiles")]
public IEnumerable<IVirtualFile> filesFind(string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
System.StringglobPattern

fileWrite(String, Object)

View Source
Declaration
[Alias("writeFile")]
public string fileWrite(string virtualPath, object contents)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath
System.Objectcontents

fileAppend(String, Object)

View Source
Declaration
[Alias("appendToFile")]
public string fileAppend(string virtualPath, object contents)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath
System.Objectcontents

fileDelete(String)

View Source
Declaration
[Alias("deleteFile")]
public string fileDelete(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

dirDelete(String)

View Source
Declaration
[Alias("deleteFile")]
public string dirDelete(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

fileReadAll(String)

View Source
Declaration
[Alias("fileTextContents")]
public string fileReadAll(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

fileReadAllBytes(String)

View Source
Declaration
[Alias("fileBytesContent")]
public byte[] fileReadAllBytes(string virtualPath)
Returns

System.Byte[]

Parameters
TypeName
System.StringvirtualPath

allFiles()

View Source
Declaration
public IEnumerable<IVirtualFile> allFiles()
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

allFiles(IVirtualPathProvider)

View Source
Declaration
public IEnumerable<IVirtualFile> allFiles(IVirtualPathProvider vfs)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs

allRootFiles()

View Source
Declaration
public IEnumerable<IVirtualFile> allRootFiles()
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

allRootFiles(IVirtualPathProvider)

View Source
Declaration
public IEnumerable<IVirtualFile> allRootFiles(IVirtualPathProvider vfs)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs

allRootDirectories()

View Source
Declaration
public IEnumerable<IVirtualDirectory> allRootDirectories()
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualDirectory>

allRootDirectories(IVirtualPathProvider)

View Source
Declaration
public IEnumerable<IVirtualDirectory> allRootDirectories(IVirtualPathProvider vfs)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualDirectory>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs

combinePath(String, String)

View Source
Declaration
public string combinePath(string basePath, string relativePath)
Returns

System.String

Parameters
TypeName
System.StringbasePath
System.StringrelativePath

combinePath(IVirtualPathProvider, String, String)

View Source
Declaration
public string combinePath(IVirtualPathProvider vfs, string basePath, string relativePath)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringbasePath
System.StringrelativePath

dir(String)

View Source
Declaration
public IVirtualDirectory dir(string virtualPath)
Returns

ServiceStack.IO.IVirtualDirectory

Parameters
TypeName
System.StringvirtualPath

dir(IVirtualPathProvider, String)

View Source
Declaration
public IVirtualDirectory dir(IVirtualPathProvider vfs, string virtualPath)
Returns

ServiceStack.IO.IVirtualDirectory

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

dirExists(String)

View Source
Declaration
public bool dirExists(string virtualPath)
Returns

System.Boolean

Parameters
TypeName
System.StringvirtualPath

dirExists(IVirtualPathProvider, String)

View Source
Declaration
public bool dirExists(IVirtualPathProvider vfs, string virtualPath)
Returns

System.Boolean

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

dirFile(String, String)

View Source
Declaration
public IVirtualFile dirFile(string dirPath, string fileName)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
System.StringdirPath
System.StringfileName

dirFile(IVirtualPathProvider, String, String)

View Source
Declaration
public IVirtualFile dirFile(IVirtualPathProvider vfs, string dirPath, string fileName)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringdirPath
System.StringfileName

dirFiles(String)

View Source
Declaration
public IEnumerable<IVirtualFile> dirFiles(string dirPath)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
System.StringdirPath

dirFiles(IVirtualPathProvider, String)

View Source
Declaration
public IEnumerable<IVirtualFile> dirFiles(IVirtualPathProvider vfs, string dirPath)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringdirPath

dirDirectory(String, String)

View Source
Declaration
public IVirtualDirectory dirDirectory(string dirPath, string dirName)
Returns

ServiceStack.IO.IVirtualDirectory

Parameters
TypeName
System.StringdirPath
System.StringdirName

dirDirectory(IVirtualPathProvider, String, String)

View Source
Declaration
public IVirtualDirectory dirDirectory(IVirtualPathProvider vfs, string dirPath, string dirName)
Returns

ServiceStack.IO.IVirtualDirectory

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringdirPath
System.StringdirName

dirDirectories(String)

View Source
Declaration
public IEnumerable<IVirtualDirectory> dirDirectories(string dirPath)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualDirectory>

Parameters
TypeName
System.StringdirPath

dirDirectories(IVirtualPathProvider, String)

View Source
Declaration
public IEnumerable<IVirtualDirectory> dirDirectories(IVirtualPathProvider vfs, string dirPath)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualDirectory>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringdirPath

findFilesInDirectory(String, String)

View Source
Declaration
public IEnumerable<IVirtualFile> findFilesInDirectory(string dirPath, string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
System.StringdirPath
System.StringglobPattern

findFilesInDirectory(IVirtualPathProvider, String, String)

View Source
Declaration
public IEnumerable<IVirtualFile> findFilesInDirectory(IVirtualPathProvider vfs, string dirPath, string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringdirPath
System.StringglobPattern

findFiles(String)

View Source
Declaration
public IEnumerable<IVirtualFile> findFiles(string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
System.StringglobPattern

dirFindFiles(IVirtualDirectory, String)

View Source
Declaration
public IEnumerable<IVirtualFile> dirFindFiles(IVirtualDirectory dir, string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualDirectorydir
System.StringglobPattern

dirFindFiles(IVirtualDirectory, String, Int32)

View Source
Declaration
public IEnumerable<IVirtualFile> dirFindFiles(IVirtualDirectory dir, string globPattern, int maxDepth)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualDirectorydir
System.StringglobPattern
System.Int32maxDepth

findFiles(IVirtualPathProvider, String)

View Source
Declaration
public IEnumerable<IVirtualFile> findFiles(IVirtualPathProvider vfs, string globPattern)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringglobPattern

findFiles(IVirtualPathProvider, String, Int32)

View Source
Declaration
public IEnumerable<IVirtualFile> findFiles(IVirtualPathProvider vfs, string globPattern, int maxDepth)
Returns

System.Collections.Generic.IEnumerable<ServiceStack.IO.IVirtualFile>

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringglobPattern
System.Int32maxDepth

fileExists(String)

View Source
Declaration
public bool fileExists(string virtualPath)
Returns

System.Boolean

Parameters
TypeName
System.StringvirtualPath

fileExists(IVirtualPathProvider, String)

View Source
Declaration
public bool fileExists(IVirtualPathProvider vfs, string virtualPath)
Returns

System.Boolean

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

file(String)

View Source
Declaration
public IVirtualFile file(string virtualPath)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
System.StringvirtualPath

file(IVirtualPathProvider, String)

View Source
Declaration
public IVirtualFile file(IVirtualPathProvider vfs, string virtualPath)
Returns

ServiceStack.IO.IVirtualFile

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

writeFile(String, Object)

View Source
Declaration
public string writeFile(string virtualPath, object contents)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath
System.Objectcontents

writeFile(IVirtualPathProvider, String, Object)

View Source
Declaration
public string writeFile(IVirtualPathProvider vfs, string virtualPath, object contents)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath
System.Objectcontents

writeFiles(IVirtualPathProvider, Dictionary<String, Object>)

View Source
Declaration
public object writeFiles(IVirtualPathProvider vfs, Dictionary<string, object> files)
Returns

System.Object

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.Collections.Generic.Dictionary<System.String,System.Object>files

writeTextFiles(IVirtualPathProvider, Dictionary<String, String>)

View Source
Declaration
public object writeTextFiles(IVirtualPathProvider vfs, Dictionary<string, string> textFiles)
Returns

System.Object

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.Collections.Generic.Dictionary<System.String,System.String>textFiles

appendToFile(String, Object)

View Source
Declaration
public string appendToFile(string virtualPath, object contents)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath
System.Objectcontents

appendToFile(IVirtualPathProvider, String, Object)

View Source
Declaration
public string appendToFile(IVirtualPathProvider vfs, string virtualPath, object contents)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath
System.Objectcontents

deleteFile(String)

View Source
Declaration
public string deleteFile(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

deleteFile(IVirtualPathProvider, String)

View Source
Declaration
public string deleteFile(IVirtualPathProvider vfs, string virtualPath)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

deleteDirectory(String)

View Source
Declaration
public string deleteDirectory(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

deleteDirectory(IVirtualPathProvider, String)

View Source
Declaration
public string deleteDirectory(IVirtualPathProvider vfs, string virtualPath)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

fileTextContents(String)

View Source
Declaration
public string fileTextContents(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

fileTextContents(IVirtualPathProvider, String)

View Source
Declaration
public string fileTextContents(IVirtualPathProvider vfs, string virtualPath)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

fileContents(IVirtualPathProvider, String)

View Source
Declaration
public object fileContents(IVirtualPathProvider vfs, string virtualPath)
Returns

System.Object

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

fileContents(Object)

View Source
Declaration
public object fileContents(object file)
Returns

System.Object

Parameters
TypeName
System.Objectfile

textContents(IVirtualFile)

View Source
Declaration
public string textContents(IVirtualFile file)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualFilefile

fileBytesContent(String)

View Source
Declaration
public byte[] fileBytesContent(string virtualPath)
Returns

System.Byte[]

Parameters
TypeName
System.StringvirtualPath

fileBytesContent(IVirtualPathProvider, String)

View Source
Declaration
public byte[] fileBytesContent(IVirtualPathProvider vfs, string virtualPath)
Returns

System.Byte[]

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

bytesContent(IVirtualFile)

View Source
Declaration
public byte[] bytesContent(IVirtualFile file)
Returns

System.Byte[]

Parameters
TypeName
ServiceStack.IO.IVirtualFilefile

fileHash(String)

View Source
Declaration
public string fileHash(string virtualPath)
Returns

System.String

Parameters
TypeName
System.StringvirtualPath

fileHash(IVirtualPathProvider, String)

View Source
Declaration
public string fileHash(IVirtualPathProvider vfs, string virtualPath)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualPathProvidervfs
System.StringvirtualPath

fileHash(IVirtualFile)

View Source
Declaration
public string fileHash(IVirtualFile file)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualFilefile

fileIsBinary(IVirtualFile)

View Source
Declaration
public bool fileIsBinary(IVirtualFile file)
Returns

System.Boolean

Parameters
TypeName
ServiceStack.IO.IVirtualFilefile

fileContentType(IVirtualFile)

View Source
Declaration
public string fileContentType(IVirtualFile file)
Returns

System.String

Parameters
TypeName
ServiceStack.IO.IVirtualFilefile

urlContents(ScriptScopeContext, String)

View Source
Declaration
public Task urlContents(ScriptScopeContext scope, string url)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl

urlContents(ScriptScopeContext, String, Object)

View Source
Declaration
public Task urlContents(ScriptScopeContext scope, string url, object options)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl
System.Objectoptions

includeUrl(ScriptScopeContext, String)

View Source
Declaration
public Task includeUrl(ScriptScopeContext scope, string url)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl

includeUrl(ScriptScopeContext, String, Object)

View Source
Declaration
public async Task includeUrl(ScriptScopeContext scope, string url, object options)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl
System.Objectoptions

urlTextContents(ScriptScopeContext, String)

View Source
Declaration
public string urlTextContents(ScriptScopeContext scope, string url)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl

urlTextContents(ScriptScopeContext, String, Object)

View Source
Declaration
public string urlTextContents(ScriptScopeContext scope, string url, object options)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl
System.Objectoptions

urlBytesContents(ScriptScopeContext, String, Object)

View Source
Declaration
public ReadOnlyMemory<byte> urlBytesContents(ScriptScopeContext scope, string url, object options)
Returns

ReadOnlyMemory<System.Byte>

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl
System.Objectoptions

CreateCacheKey(String, Dictionary<String, Object>)

View Source
Declaration
public static string CreateCacheKey(string url, Dictionary<string, object> options = null)
Returns

System.String

Parameters
TypeName
System.Stringurl
System.Collections.Generic.Dictionary<System.String,System.Object>options

fileContentsWithCache(ScriptScopeContext, String)

View Source
Declaration
public Task fileContentsWithCache(ScriptScopeContext scope, string virtualPath)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath

fileContentsWithCache(ScriptScopeContext, String, Object)

View Source
Declaration
public Task fileContentsWithCache(ScriptScopeContext scope, string virtualPath, object options)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath
System.Objectoptions

includeFileWithCache(ScriptScopeContext, String)

View Source
Declaration
public Task includeFileWithCache(ScriptScopeContext scope, string virtualPath)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath

includeFileWithCache(ScriptScopeContext, String, Object)

View Source
Declaration
public async Task includeFileWithCache(ScriptScopeContext scope, string virtualPath, object options)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringvirtualPath
System.Objectoptions

urlContentsWithCache(ScriptScopeContext, String)

View Source
Declaration
public Task urlContentsWithCache(ScriptScopeContext scope, string url)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl

urlContentsWithCache(ScriptScopeContext, String, Object)

View Source
Declaration
public Task urlContentsWithCache(ScriptScopeContext scope, string url, object options)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl
System.Objectoptions

includeUrlWithCache(ScriptScopeContext, String)

View Source
Declaration
public Task includeUrlWithCache(ScriptScopeContext scope, string url)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl

includeUrlWithCache(ScriptScopeContext, String, Object)

View Source
Declaration
public async Task includeUrlWithCache(ScriptScopeContext scope, string url, object options)
Returns

System.Threading.Tasks.Task

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringurl
System.Objectoptions

scriptMethods(ScriptScopeContext)

View Source
Declaration
public List<ScriptMethodInfo> scriptMethods(ScriptScopeContext scope)
Returns

System.Collections.Generic.List<ServiceStack.Script.ScriptMethodInfo>

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope

scriptMethodNames(ScriptScopeContext)

View Source
Declaration
public List<string> scriptMethodNames(ScriptScopeContext scope)
Returns

System.Collections.Generic.List<System.String>

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope

scriptMethodSignatures(ScriptScopeContext)

View Source
Declaration
public List<string> scriptMethodSignatures(ScriptScopeContext scope)
Returns

System.Collections.Generic.List<System.String>

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope

methods(Object)

View Source
Declaration
public List<string> methods(object o)
Returns

System.Collections.Generic.List<System.String>

Parameters
TypeName
System.Objecto

methodTypes(Object)

View Source
Declaration
public ScriptMethodInfo[] methodTypes(object o)
Returns

ServiceStack.Script.ScriptMethodInfo[]

Parameters
TypeName
System.Objecto

staticMethods(Object)

View Source
Declaration
public List<string> staticMethods(object o)
Returns

System.Collections.Generic.List<System.String>

Parameters
TypeName
System.Objecto

staticMethodTypes(Object)

View Source
Declaration
public ScriptMethodInfo[] staticMethodTypes(object o)
Returns

ServiceStack.Script.ScriptMethodInfo[]

Parameters
TypeName
System.Objecto

allMethodTypes(Object)

View Source
Declaration
public ScriptMethodInfo[] allMethodTypes(object o)
Returns

ServiceStack.Script.ScriptMethodInfo[]

Parameters
TypeName
System.Objecto

allMemberInfos(Object)

View Source
Declaration
public MemberInfo[] allMemberInfos(object o)
Returns

System.Reflection.MemberInfo[]

Parameters
TypeName
System.Objecto

cacheClear(ScriptScopeContext, Object)

View Source
Declaration
public object cacheClear(ScriptScopeContext scope, object cacheNames)
Returns

System.Object

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.ObjectcacheNames

invalidateAllCaches(ScriptScopeContext)

View Source
Declaration
public object invalidateAllCaches(ScriptScopeContext scope)
Returns

System.Object

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope

sh(ScriptScopeContext, String)

View Source
Declaration
public string sh(ScriptScopeContext scope, string arguments)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringarguments

sh(ScriptScopeContext, String, Dictionary<String, Object>)

View Source
Declaration
public string sh(ScriptScopeContext scope, string arguments, Dictionary<string, object> options)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringarguments
System.Collections.Generic.Dictionary<System.String,System.Object>options

proc(ScriptScopeContext, String)

View Source
Declaration
public string proc(ScriptScopeContext scope, string fileName)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringfileName

proc(ScriptScopeContext, String, Dictionary<String, Object>)

View Source
Declaration
public string proc(ScriptScopeContext scope, string fileName, Dictionary<string, object> options)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.StringfileName
System.Collections.Generic.Dictionary<System.String,System.Object>options

exePath(String)

View Source
Declaration
public string exePath(string exeName)
Returns

System.String

Parameters
TypeName
System.StringexeName

exit(Int32)

View Source
Declaration
public StopExecution exit(int exitCode)
Returns

ServiceStack.Script.StopExecution

Parameters
TypeName
System.Int32exitCode

inspectVars(Object)

View Source
Declaration
public IgnoreResult inspectVars(object vars)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Objectvars

mv(ScriptScopeContext, String, String)

View Source
Declaration
public string mv(ScriptScopeContext scope, string from, string to)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringfrom
System.Stringto

cp(ScriptScopeContext, String, String)

View Source
Declaration
public string cp(ScriptScopeContext scope, string from, string to)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringfrom
System.Stringto

xcopy(ScriptScopeContext, String, String)

View Source
Declaration
public string xcopy(ScriptScopeContext scope, string from, string to)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringfrom
System.Stringto

rm(ScriptScopeContext, String, String)

View Source
Declaration
public string rm(ScriptScopeContext scope, string from, string to)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringfrom
System.Stringto

rmdir(ScriptScopeContext, String)

View Source
Declaration
public string rmdir(ScriptScopeContext scope, string target)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringtarget

mkdir(ScriptScopeContext, String)

View Source
Declaration
public string mkdir(ScriptScopeContext scope, string target)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringtarget

cat(ScriptScopeContext, String)

View Source
Declaration
public string cat(ScriptScopeContext scope, string target)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringtarget

touch(ScriptScopeContext, String)

View Source
Declaration
public string touch(ScriptScopeContext scope, string target)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.ScriptScopeContextscope
System.Stringtarget

File()

View Source
Declaration
public FileScripts File()
Returns

ServiceStack.Script.FileScripts

Directory()

View Source
Declaration
public DirectoryScripts Directory()
Returns

ServiceStack.Script.DirectoryScripts

sha1(Object)

View Source
Declaration
public string sha1(object target)
Returns

System.String

Parameters
TypeName
System.Objecttarget

sha256(Object)

View Source
Declaration
public string sha256(object target)
Returns

System.String

Parameters
TypeName
System.Objecttarget

sha512(Object)

View Source
Declaration
public string sha512(object target)
Returns

System.String

Parameters
TypeName
System.Objecttarget

Delete(String)

View Source
Declaration
public IgnoreResult Delete(string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath

Delete(IOScript, String)

View Source
Declaration
public IgnoreResult Delete(IOScript os, string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.IOScriptos
System.Stringpath

Exists(String)

View Source
Declaration
public bool Exists(string path)
Returns

System.Boolean

Parameters
TypeName
System.Stringpath

Exists(IOScript, String)

View Source
Declaration
public bool Exists(IOScript os, string path)
Returns

System.Boolean

Parameters
TypeName
ServiceStack.Script.IOScriptos
System.Stringpath

Move(String, String)

View Source
Declaration
public IgnoreResult Move(string from, string to)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringfrom
System.Stringto

Move(IOScript, String, String)

View Source
Declaration
public IgnoreResult Move(IOScript os, string from, string to)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.IOScriptos
System.Stringfrom
System.Stringto

Copy(String, String)

View Source
Declaration
public IgnoreResult Copy(string from, string to)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringfrom
System.Stringto

Copy(IOScript, String, String)

View Source
Declaration
public IgnoreResult Copy(IOScript os, string from, string to)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.IOScriptos
System.Stringfrom
System.Stringto

Create(String, String)

View Source
Declaration
public IgnoreResult Create(string from, string to)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringfrom
System.Stringto

Create(FileScripts, String, String)

View Source
Declaration
public IgnoreResult Create(FileScripts fs, string from, string to)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringfrom
System.Stringto

Decrypt(String)

View Source
Declaration
public IgnoreResult Decrypt(string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath

Decrypt(FileScripts, String)

View Source
Declaration
public IgnoreResult Decrypt(FileScripts fs, string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath

Encrypt(String)

View Source
Declaration
public IgnoreResult Encrypt(string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath

Encrypt(FileScripts, String)

View Source
Declaration
public IgnoreResult Encrypt(FileScripts fs, string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath

Replace(String, String, String)

View Source
Declaration
public IgnoreResult Replace(string from, string to, string backup)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringfrom
System.Stringto
System.Stringbackup

Replace(FileScripts, String, String, String)

View Source
Declaration
public IgnoreResult Replace(FileScripts fs, string from, string to, string backup)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringfrom
System.Stringto
System.Stringbackup

ReadAllBytes(String)

View Source
Declaration
public byte[] ReadAllBytes(string path)
Returns

System.Byte[]

Parameters
TypeName
System.Stringpath

ReadAllBytes(FileScripts, String)

View Source
Declaration
public byte[] ReadAllBytes(FileScripts fs, string path)
Returns

System.Byte[]

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath

ReadAllLines(String)

View Source
Declaration
public string[] ReadAllLines(string path)
Returns

System.String[]

Parameters
TypeName
System.Stringpath

ReadAllLines(FileScripts, String)

View Source
Declaration
public string[] ReadAllLines(FileScripts fs, string path)
Returns

System.String[]

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath

ReadAllText(String)

View Source
Declaration
public string ReadAllText(string path)
Returns

System.String

Parameters
TypeName
System.Stringpath

ReadAllText(FileScripts, String)

View Source
Declaration
public string ReadAllText(FileScripts fs, string path)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath

WriteAllBytes(String, Byte[])

View Source
Declaration
public IgnoreResult WriteAllBytes(string path, byte[] bytes)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath
System.Byte[]bytes

WriteAllBytes(FileScripts, String, Byte[])

View Source
Declaration
public IgnoreResult WriteAllBytes(FileScripts fs, string path, byte[] bytes)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath
System.Byte[]bytes

WriteAllLines(String, String[])

View Source
Declaration
public IgnoreResult WriteAllLines(string path, string[] lines)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath
System.String[]lines

WriteAllLines(FileScripts, String, String[])

View Source
Declaration
public IgnoreResult WriteAllLines(FileScripts fs, string path, string[] lines)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath
System.String[]lines

WriteAllText(String, String)

View Source
Declaration
public IgnoreResult WriteAllText(string path, string text)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath
System.Stringtext

WriteAllText(FileScripts, String, String)

View Source
Declaration
public IgnoreResult WriteAllText(FileScripts fs, string path, string text)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath
System.Stringtext

AppendAllLines(String, String[])

View Source
Declaration
public IgnoreResult AppendAllLines(string path, string[] lines)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath
System.String[]lines

AppendAllLines(FileScripts, String, String[])

View Source
Declaration
public IgnoreResult AppendAllLines(FileScripts fs, string path, string[] lines)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath
System.String[]lines

AppendAllText(String, String)

View Source
Declaration
public IgnoreResult AppendAllText(string path, string text)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath
System.Stringtext

AppendAllText(FileScripts, String, String)

View Source
Declaration
public IgnoreResult AppendAllText(FileScripts fs, string path, string text)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.FileScriptsfs
System.Stringpath
System.Stringtext

CreateDirectory(String)

View Source
Declaration
public IgnoreResult CreateDirectory(string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
System.Stringpath

CreateDirectory(DirectoryScripts, String)

View Source
Declaration
public IgnoreResult CreateDirectory(DirectoryScripts ds, string path)
Returns

ServiceStack.Script.IgnoreResult

Parameters
TypeName
ServiceStack.Script.DirectoryScriptsds
System.Stringpath

GetDirectories(String)

View Source
Declaration
public string[] GetDirectories(string path)
Returns

System.String[]

Parameters
TypeName
System.Stringpath

GetDirectories(DirectoryScripts, String)

View Source
Declaration
public string[] GetDirectories(DirectoryScripts ds, string path)
Returns

System.String[]

Parameters
TypeName
ServiceStack.Script.DirectoryScriptsds
System.Stringpath

GetFiles(String)

View Source
Declaration
public string[] GetFiles(string path)
Returns

System.String[]

Parameters
TypeName
System.Stringpath

GetFiles(DirectoryScripts, String)

View Source
Declaration
public string[] GetFiles(DirectoryScripts ds, string path)
Returns

System.String[]

Parameters
TypeName
ServiceStack.Script.DirectoryScriptsds
System.Stringpath

GetLogicalDrives()

View Source
Declaration
public string[] GetLogicalDrives()
Returns

System.String[]

GetLogicalDrives(DirectoryScripts)

View Source
Declaration
public string[] GetLogicalDrives(DirectoryScripts ds)
Returns

System.String[]

Parameters
TypeName
ServiceStack.Script.DirectoryScriptsds

GetCurrentDirectory()

View Source
Declaration
public string GetCurrentDirectory()
Returns

System.String

GetCurrentDirectory(DirectoryScripts)

View Source
Declaration
public string GetCurrentDirectory(DirectoryScripts ds)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.DirectoryScriptsds

GetDirectoryRoot(String)

View Source
Declaration
public string GetDirectoryRoot(string path)
Returns

System.String

Parameters
TypeName
System.Stringpath

GetDirectoryRoot(DirectoryScripts, String)

View Source
Declaration
public string GetDirectoryRoot(DirectoryScripts ds, string path)
Returns

System.String

Parameters
TypeName
ServiceStack.Script.DirectoryScriptsds
System.Stringpath

Inherited Methods

GetInvoker(String, Int32, InvokerType)

View Source
Declaration
public MethodInvoker GetInvoker(string name, int argsCount, InvokerType type)
Returns

ServiceStack.MethodInvoker

Parameters
TypeName
System.Stringname
System.Int32argsCount
ServiceStack.Script.InvokerTypetype

QueryFilters(String)

View Source
Declaration
public List<MethodInfo> QueryFilters(string filterName)
Returns

System.Collections.Generic.List<System.Reflection.MethodInfo>

Parameters
TypeName
System.StringfilterName