Bagikan melalui


WebSiteProjectRelatedFilesAttribute Kelas

Definisi

Atribut ini memungkinkan Proyek Situs Web untuk menumpuk satu tipe file (terkait) di bawah tipe file lain (utama) di penjelajah solusi

public ref class WebSiteProjectRelatedFilesAttribute sealed : Microsoft::VisualStudio::Shell::RegistrationAttribute
public ref class WebSiteProjectRelatedFilesAttribute sealed : Microsoft::VisualStudio::Shell::RegistrationAttribute
[System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple=true, Inherited=true)]
[System.Runtime.InteropServices.ComVisible(false)]
public sealed class WebSiteProjectRelatedFilesAttribute : Microsoft.VisualStudio.Shell.RegistrationAttribute
[<System.AttributeUsage(System.AttributeTargets.Class, AllowMultiple=true, Inherited=true)>]
[<System.Runtime.InteropServices.ComVisible(false)>]
type WebSiteProjectRelatedFilesAttribute = class
    inherit RegistrationAttribute
Public NotInheritable Class WebSiteProjectRelatedFilesAttribute
Inherits RegistrationAttribute
Warisan
WebSiteProjectRelatedFilesAttribute
Atribut

Keterangan

Sebagai contoh definisi Atribut berikut [WebSiteProjectRelatedFiles("aspx","py")]

akan menambahkan kunci registri berikut: [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\(*version*)\Projects\ {E24C65DC-7377-472B-9ABA-BC803B73C61A}\RelatedFiles\.aspx\.py "Default"=""

Konstruktor

WebSiteProjectRelatedFilesAttribute(String, String)

Membuat atribut WebSiteProjectAttribute baru untuk mendaftarkan bahasa dengan proyek situs web

Properti

PrimaryFileExtension

Mendapatkan ekstensi file utama yang akan menumpuk file

RelatedFileExtension

Mendapatkan pengecualian file terkait yang akanl bersarang di bawah ekstensi file utama

TypeId

Ambil alih properti TypeID untuk memungkinkan RegistrationAttribute memperoleh kelas untuk bekerja dengan System.ComponentModel.TypeDescriptor.GetAttributes(...). Atribut yang berasal dari atribut ini harus mengambil alih properti ini hanya jika membutuhkan kontrol yang lebih baik pada instans yang dapat diterapkan ke kelas.

(Diperoleh dari RegistrationAttribute)

Metode

GetPackageRegKeyPath(Guid)

Mendapatkan jalur registri (relatif terhadap akar registri aplikasi) dari VSPackage.

(Diperoleh dari RegistrationAttribute)
Register(RegistrationAttribute+RegistrationContext)

Dipanggil untuk mendaftarkan atribut ini dengan konteks yang diberikan. Konteks berisi lokasi tempat informasi pendaftaran harus ditempatkan. Ini juga berisi informasi lain seperti jenis yang didaftarkan dan informasi jalur.

Unregister(RegistrationAttribute+RegistrationContext)

Batalkan pendaftaran ekstensi file terkait ini

Berlaku untuk