appattr

package
v0.0.0-...-10ffbd2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 20, 2022 License: MIT Imports: 2 Imported by: 0

Documentation

Rendered for windows/amd64

Overview

Package appattr describes the attributes of unpackaged (aka "Classic" or "Desktop") applications in Windows.

Index

Constants

View Source
const DateLayout = "20060102"

DateLayout can be used with Time.Format to format installation dates.

Variables

This section is empty.

Functions

This section is empty.

Types

type List

type List []Value

List is a list of application attributes.

func (List) Get

func (list List) Get(name string) (v Value, ok bool)

Get returns the first attribute in the list with the given name, if present. It returns false if an attribute with that name is not present.

func (List) GetString

func (list List) GetString(name string) string

Get returns the first attribute in the list with the given name as a string. If the attribute is not present it returns an empty string.

type Type

type Type uint32

Type identifies the type of an attribute.

When attributes are written to the registry, their type determines the type of registry value that will be written.

const (
	TypeNone   Type = registry.NONE
	TypeString Type = registry.SZ
	TypeExpand Type = registry.EXPAND_SZ
	TypeUint32 Type = registry.DWORD
)

Supported attribute types.

type Value

type Value struct {
	Name string
	Data string
	Type Type
}

Value is an application attribute that can be recorded in the Windows registry.

func AuthorizedCDFPrefix

func AuthorizedCDFPrefix(data string) Value

AuthorizedCDFPrefix returns an AuthorizedCDFPrefix attribute.

func Comments

func Comments(data string) Value

Comments returns a Comments attribute.

func Contact

func Contact(data string) Value

Contact returns a Contact attribute.

func DisplayIcon

func DisplayIcon(data string) Value

DisplayIcon returns an DisplayIcon attribute.

func DisplayName

func DisplayName(data string) Value

DisplayName returns a DisplayName attribute.

func DisplayVersion

func DisplayVersion(data string) Value

DisplayVersion returns a DisplayVersion attribute.

func EstimatedSize

func EstimatedSize(kb uint32) Value

EstimatedSize returns an EstimatedSize attribute. The size is in KB.

func HelpLink(data string) Value

HelpLink returns a HelpLink attribute.

func HelpTelephone

func HelpTelephone(data string) Value

HelpTelephone returns a HelpTelephone attribute.

func InstallDate

func InstallDate(data string) Value

InstallDate returns an InstallDate attribute.

func InstallLocation

func InstallLocation(data string) Value

InstallLocation returns an InstallLocation attribute.

func InstallSource

func InstallSource(data string) Value

InstallSource returns an InstallSource attribute.

func Language

func Language(data string) Value

Language returns a Language attribute.

func ModifyPath

func ModifyPath(data string) Value

ModifyPath returns a ModifyPath attribute.

func Publisher

func Publisher(data string) Value

Publisher returns a Publisher attribute.

func Readme

func Readme(data string) Value

Readme returns a Readme attribute.

func SettingsIdentifier

func SettingsIdentifier(data string) Value

SettingsIdentifier returns an SettingsIdentifier attribute.

func URLInfoAbout

func URLInfoAbout(data string) Value

URLInfoAbout returns a URLInfoAbout attribute.

func URLUpdateInfo

func URLUpdateInfo(data string) Value

URLUpdateInfo returns a URLUpdateInfo attribute.

func UninstallString

func UninstallString(data string) Value

UninstallString returns an UninstallString attribute.

func Version

func Version(data uint32) Value

Version returns a Version attribute.

func VersionMajor

func VersionMajor(data uint32) Value

VersionMajor returns a VersionMajor attribute.

func VersionMinor

func VersionMinor(data uint32) Value

VersionMinor returns a VersionMinor attribute.

func (Value) String

func (v Value) String() string

String returns a string representation of the attribute.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL