Stride

OPEN / CLOSE
  • Features
  • Blog
  • Documentation
  • Community
(icon) Download

  • Discord
  • Facebook
  • Twitter
  • YouTube

LANGUAGE

OPEN / CLOSE
  • English
  • 日本語
    Show / Hide Table of Contents

    SourceCodeAsset Class

    Namespace: Stride.Core.Assets
    Assembly: Stride.Core.Assets.dll

    Class SourceCodeAsset.

    System.Object → Asset → SourceCodeAsset
    Derived from SourceCodeAsset: ProjectSourceCodeAsset

    [DataContract("SourceCodeAsset")]
    public abstract class SourceCodeAsset : Asset
    Name Description
    Properties
    InternalSerializableTextAccessor

    Used internally by serialization.

    Text

    Gets the sourcecode text.

    TextAccessor
    Methods
    GenerateIdFromLocation(String, String)

    Generates a unique identifier from location.

    Save(Stream)

    Saves the content to a stream.

    | Improve this Doc View Source

    Properties


    InternalSerializableTextAccessor

    Used internally by serialization.

    [DataMember(DataMemberMode.Assign)]
    [Display(null, null, Browsable = false)]
    public ISerializableTextAccessor InternalSerializableTextAccessor { get; set; }
    Property Value
    Type Description
    ISerializableTextAccessor

    Text

    Gets the sourcecode text.

    [Display(null, null, Browsable = false)]
    public string Text { get; set; }
    Property Value
    Type Description
    System.String

    The sourcecode text.


    TextAccessor

    [Display(null, null, Browsable = false)]
    public ITextAccessor TextAccessor { get; set; }
    Property Value
    Type Description
    ITextAccessor
    | Improve this Doc View Source

    Methods


    GenerateIdFromLocation(String, String)

    Generates a unique identifier from location.

    public static AssetId GenerateIdFromLocation(string packageName, string location)
    Parameters
    Type Name Description
    System.String packageName
    System.String location

    The location.

    Returns
    Type Description
    AssetId

    Guid.


    Save(Stream)

    Saves the content to a stream.

    public virtual void Save(Stream stream)
    Parameters
    Type Name Description
    System.IO.Stream stream

    Inherited Members

    Asset.Id
    Asset.SerializedVersion
    Asset.Tags
    Asset.Archetype
    Asset.MainSource
    Asset.CreateDerivedAsset(String)
    Asset.CreateDerivedAsset(String, Dictionary<Guid, Guid>)
    Asset.ToString()

    Extension Methods

    ComponentBaseExtensions.DisposeBy<T>(T, ICollectorHolder)
    ComponentBaseExtensions.RemoveDisposeBy<T>(T, ICollectorHolder)
    • Improve this Doc
    • View Source
    In This Article

    Back to top

    Copyright © 2019-2021 .NET Foundation and Contributors
    Supported by the .NET Foundation