Gorgon
Show / Hide Table of Contents

Class SaveAsService

A service used to present a save as dialog for the project file system.

Inheritance
object
SaveAsService
Implements
ISaveAsService
Inherited Members
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
Namespace: Gorgon.Editor.Services
Assembly: Gorgon.Editor.API.dll
Syntax
public class SaveAsService : ISaveAsService

Constructors

| Edit this page View Source

SaveAsService(IContentFileManager)

Initializes a new instance of the SaveAsService class.

Declaration
public SaveAsService(IContentFileManager fileManager)
Parameters
Type Name Description
IContentFileManager fileManager

The file manager for the project.

Exceptions
Type Condition
ArgumentNullException

Thrown when the fileManager parameter is null.

Methods

| Edit this page View Source

SaveAs(string, string, string)

Function to present a means of providing a path for a save as operation.

Declaration
public string SaveAs(string currentFileName, string filesOfType, string typeKey = "Type")
Parameters
Type Name Description
string currentFileName

The current file name.

string filesOfType

The file type to search for.

string typeKey

[Optional] The key to check in the file metadata for the file type.

Returns
Type Description
string

The selected file path to save the file as.

Implements

ISaveAsService

Extension Methods

GorgonDebugExtensions.ValidateObject<T>(T, string)
GorgonNullExtensions.AsNullable<T>(object)
GorgonNullExtensions.IfNull<T>(object, T)
GorgonNullExtensions.IsNull(object)
  • Edit this page
  • View Source
In this article
Back to top Copyright 2023 - Licensed under the MIT license by Michael Winsor (Tape_Worm).
Send comments on this topic to the author