Class: WMI::Win32_Printer

Inherits:
Base
  • Object
show all
Defined in:
lib/Win32_Printer.rb

Overview

Win32_Printer クラスは、メディアの画像イメージを再生できる Win32 コンピュータ システムに接続されているデバイスを表します。

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Methods inherited from Base

#AddRef, #AssociatorsAsync_, #Associators_, #Clone_, #CompareTo_, #DeleteAsync_, #Delete_, #Derivation_, #ExecMethodAsync_, #ExecMethod_, #GetIDsOfNames, #GetObjectText_, #GetText_, #GetTypeInfo, #GetTypeInfoCount, #InstancesAsync_, #Instances_, #Invoke, #Methods_, #Path_, #Properties_, #PutAsync_, #Put_, #Qualifiers_, #QueryInterface, #ReferencesAsync_, #References_, #Refresh_, #Release, #Security_, #SetFromText_, #SpawnDerivedClass_, #SpawnInstance_, #SubclassesAsync_, #Subclasses_, #SystemProperties_

Instance Attribute Details

- (uint32) Attributes

Attributes プロパティは、Win32 印刷デバイスの属性を示します。

 

Returns:

  • (uint32)

    Attributes



158
159
160
# File 'lib/Win32_Printer.rb', line 158

def Attributes
  @Attributes
end

- (uint16) Availability (readonly)

デバイスの利用可能性と状態です。

 

Returns:

  • (uint16)

    Availability



168
169
170
# File 'lib/Win32_Printer.rb', line 168

def Availability
  @Availability
end

- (string) AvailableJobSheets (readonly)

プリンタで利用可能なすべてのジョブ シートを記述しています。

 

Returns:

  • (string)

    AvailableJobSheets



175
176
177
# File 'lib/Win32_Printer.rb', line 175

def AvailableJobSheets
  @AvailableJobSheets
end

- (uint32) AveragePagesPerMinute (readonly)

AveragePagesPerMinute プロパティにより、プリンタでサポートされる速度 (分単位による平均ページ数) が指定されます。

Returns:

  • (uint32)

    AveragePagesPerMinute



180
181
182
# File 'lib/Win32_Printer.rb', line 180

def AveragePagesPerMinute
  @AveragePagesPerMinute
end

- (uint16) Capabilities (readonly)

プリンタ機能を示す整数の配列です。

 "両面印刷" (

Returns:

  • (uint16)

    Capabilities



186
187
188
# File 'lib/Win32_Printer.rb', line 186

def Capabilities
  @Capabilities
end

- (string) CapabilityDescriptions (readonly)

Capabilities 配列で示されるプリンタ機能に詳細な説明を提供する自由形式の文字列の配列です。

 

Returns:

  • (string)

    CapabilityDescriptions



192
193
194
# File 'lib/Win32_Printer.rb', line 192

def CapabilityDescriptions
  @CapabilityDescriptions
end

- (string) Caption (readonly)

Caption プロパティは、オブジェクトについての簡単な説明 (1 行分の文字列) です。

Returns:

  • (string)

    Caption



197
198
199
# File 'lib/Win32_Printer.rb', line 197

def Caption
  @Caption
end

- (string) CharSetsSupported (readonly)

プリンタの管理に関連するテキストの出力に利用可能な文字セットを示します。

  

Returns:

  • (string)

    CharSetsSupported



204
205
206
# File 'lib/Win32_Printer.rb', line 204

def CharSetsSupported
  @CharSetsSupported
end

- (string) Comment

Comment プロパティにより、印刷キューのコメントが指定されます。

 

Returns:

  • (string)

    Comment



211
212
213
# File 'lib/Win32_Printer.rb', line 211

def Comment
  @Comment
end

- (uint32) ConfigManagerErrorCode (readonly)

Win32 構成マネージャのエラー コードを示します。

 

Returns:

  • (uint32)

    ConfigManagerErrorCode



284
285
286
# File 'lib/Win32_Printer.rb', line 284

def ConfigManagerErrorCode
  @ConfigManagerErrorCode
end

- (boolean) ConfigManagerUserConfig (readonly)

デバイスがユーザー定義の構成を使用しているかどうかを示します。

Returns:

  • (boolean)

    ConfigManagerUserConfig



289
290
291
# File 'lib/Win32_Printer.rb', line 289

def ConfigManagerUserConfig
  @ConfigManagerUserConfig
end

- (string) CreationClassName (readonly)

CreationClassName は、インスタンスの作成で使用されるクラス名、またはサブクラス名を示します。

 

Returns:

  • (string)

    CreationClassName



295
296
297
# File 'lib/Win32_Printer.rb', line 295

def CreationClassName
  @CreationClassName
end

- (uint16) CurrentCapabilities (readonly)

現在使用されている、仕上がりとプリンタのほかの機能を指定します。

 

Returns:

  • (uint16)

    CurrentCapabilities



301
302
303
# File 'lib/Win32_Printer.rb', line 301

def CurrentCapabilities
  @CurrentCapabilities
end

- (string) CurrentCharSet (readonly)

プリンタの管理に関連するテキストの出力に使用されている現在の文字セットを指定します。

  

Returns:

  • (string)

    CurrentCharSet



309
310
311
# File 'lib/Win32_Printer.rb', line 309

def CurrentCharSet
  @CurrentCharSet
end

- (uint16) CurrentLanguage (readonly)

現在使用中のプリンタの言語を示します。

 

Returns:

  • (uint16)

    CurrentLanguage



315
316
317
# File 'lib/Win32_Printer.rb', line 315

def CurrentLanguage
  @CurrentLanguage
end

- (string) CurrentMimeType (readonly)

CurrentLanguage が MIME の種類が使用中であることを示す設定である場合は (値 = 47)、プリンタに現在使用されている MIME の種類を指定します。

Returns:

  • (string)

    CurrentMimeType



320
321
322
# File 'lib/Win32_Printer.rb', line 320

def CurrentMimeType
  @CurrentMimeType
end

- (string) CurrentNaturalLanguage (readonly)

管理用のプリンタに現在使用されている言語を示します。

 CurrentNaturalLanguage 

Returns:

  • (string)

    CurrentNaturalLanguage



327
328
329
# File 'lib/Win32_Printer.rb', line 327

def CurrentNaturalLanguage
  @CurrentNaturalLanguage
end

- (string) CurrentPaperType (readonly)

プリンタが現在使用中の用紙の種類を指定します。

 

Returns:

  • (string)

    CurrentPaperType



334
335
336
# File 'lib/Win32_Printer.rb', line 334

def CurrentPaperType
  @CurrentPaperType
end

- (boolean) Default (readonly)

Default プロパティにより、コンピュータで通常使うプリンタであるかどうかが示されます。

Returns:

  • (boolean)

    Default



339
340
341
# File 'lib/Win32_Printer.rb', line 339

def Default
  @Default
end

- (uint16) DefaultCapabilities (readonly)

仕上がりおよびプリンタのほかの機能の既定の設定を指定します。

 DefaultCapabilities 

Returns:

  • (uint16)

    DefaultCapabilities



346
347
348
# File 'lib/Win32_Printer.rb', line 346

def DefaultCapabilities
  @DefaultCapabilities
end

- (uint32) DefaultCopies (readonly)

指定されていない場合に 単一のジョブで印刷される部数です。

Returns:

  • (uint32)

    DefaultCopies



351
352
353
# File 'lib/Win32_Printer.rb', line 351

def DefaultCopies
  @DefaultCopies
end

- (uint16) DefaultLanguage (readonly)

プリンタの既定の言語を示します。

 

Returns:

  • (uint16)

    DefaultLanguage



357
358
359
# File 'lib/Win32_Printer.rb', line 357

def DefaultLanguage
  @DefaultLanguage
end

- (string) DefaultMimeType (readonly)

DefaultLanguage が MIME の種類が使用中であることを示す設定である場合は (値 = 47)、プリンタに使用される既定の MIME の種類を指定します。

Returns:

  • (string)

    DefaultMimeType



362
363
364
# File 'lib/Win32_Printer.rb', line 362

def DefaultMimeType
  @DefaultMimeType
end

- (uint32) DefaultNumberUp (readonly)

ジョブに指定が去れていない場合に、プリンタが単一のメディア シートに送る印刷 - ストリームの最大部数です。

Returns:

  • (uint32)

    DefaultNumberUp



367
368
369
# File 'lib/Win32_Printer.rb', line 367

def DefaultNumberUp
  @DefaultNumberUp
end

- (string) DefaultPaperType (readonly)

印刷ジョブが特定の種類を指定しない場合は、プリンタが使用する用紙の種類を指定します。

 

Returns:

  • (string)

    DefaultPaperType



374
375
376
# File 'lib/Win32_Printer.rb', line 374

def DefaultPaperType
  @DefaultPaperType
end

- (uint32) DefaultPriority

DefaultPriority プロパティにより、各印刷ジョブに割り当てられた既定の優先値が指定されます。

Returns:

  • (uint32)

    DefaultPriority



379
380
381
# File 'lib/Win32_Printer.rb', line 379

def DefaultPriority
  @DefaultPriority
end

- (string) Description (readonly)

Description プロパティでオブジェクトの説明が提供されます。

Returns:

  • (string)

    Description



385
386
387
# File 'lib/Win32_Printer.rb', line 385

def Description
  @Description
end

- (uint16) DetectedErrorState (readonly)

プリンタ エラー情報です。

Returns:

  • (uint16)

    DetectedErrorState



390
391
392
# File 'lib/Win32_Printer.rb', line 390

def DetectedErrorState
  @DetectedErrorState
end

- (string) DeviceID (readonly)

DeviceID プロパティには、プリンタをシステム上のほかのデバイスと一意に識別する文字列が含まれています。

Returns:

  • (string)

    DeviceID



395
396
397
# File 'lib/Win32_Printer.rb', line 395

def DeviceID
  @DeviceID
end

- (boolean) Direct

Direct プロパティにより、印刷ジョブがプリンタに直接送られるべきであるかどうかが示されます。

 

Returns:

  • (boolean)

    Direct



402
403
404
# File 'lib/Win32_Printer.rb', line 402

def Direct
  @Direct
end

- (boolean) DoCompleteFirst

DoCompleteFirst プロパティにより、スプールを終えたジョブをプリンタが受信したジョブの順番とは対照的に開始するべきかどうかを示します。

Returns:

  • (boolean)

    DoCompleteFirst



407
408
409
# File 'lib/Win32_Printer.rb', line 407

def DoCompleteFirst
  @DoCompleteFirst
end

- (string) DriverName

DriverName プロパティにより、Win32 プリンタ ドライバの名前が指定されます。

 

Returns:

  • (string)

    DriverName



414
415
416
# File 'lib/Win32_Printer.rb', line 414

def DriverName
  @DriverName
end

- (boolean) EnableBIDI

EnableBIDI プロパティにより、プリンタの双方向印刷が可能かどうかが示されます。

Returns:

  • (boolean)

    EnableBIDI



419
420
421
# File 'lib/Win32_Printer.rb', line 419

def EnableBIDI
  @EnableBIDI
end

- (boolean) EnableDevQueryPrint

EnableDevQueryPrint プロパティにより、ドキュメントとプリンタの設定が合わない場合に、キューでドキュメントを保留するかどうかが示されます

Returns:

  • (boolean)

    EnableDevQueryPrint



424
425
426
# File 'lib/Win32_Printer.rb', line 424

def EnableDevQueryPrint
  @EnableDevQueryPrint
end

- (boolean) ErrorCleared (readonly)

ErrorCleared は LastErrorCode プロパティで報告されたエラーが現在は消去されていることを示すブール値のプロパティです。

Returns:

  • (boolean)

    ErrorCleared



429
430
431
# File 'lib/Win32_Printer.rb', line 429

def ErrorCleared
  @ErrorCleared
end

- (string) ErrorDescription (readonly)

ErrorDescription は LastErrorCode プロパティで記録されたエラーに関する情報および実行される可能性がある修正の情報を提供する自由形式の文字列です。

Returns:

  • (string)

    ErrorDescription



434
435
436
# File 'lib/Win32_Printer.rb', line 434

def ErrorDescription
  @ErrorDescription
end

- (string) ErrorInformation

現在のエラー状態の補足情報を提供しているDetectedErrorState で示されている配列です。

Returns:

  • (string)

    ErrorInformation



439
440
441
# File 'lib/Win32_Printer.rb', line 439

def ErrorInformation
  @ErrorInformation
end

- (uint16) ExtendedDetectedErrorState (readonly)

ExtendedDetectedErrorState プロパティにより、標準エラー情報が報告されます。

 

Returns:

  • (uint16)

    ExtendedDetectedErrorState



445
446
447
# File 'lib/Win32_Printer.rb', line 445

def ExtendedDetectedErrorState
  @ExtendedDetectedErrorState
end

- (uint16) ExtendedPrinterStatus (readonly)

論理デバイスの Availability プロパティで指定されたプリンタの状態よりも詳細な情報です。

 

Returns:

  • (uint16)

    ExtendedPrinterStatus



451
452
453
# File 'lib/Win32_Printer.rb', line 451

def ExtendedPrinterStatus
  @ExtendedPrinterStatus
end

- (boolean) Hidden

Hidden プロパティにより、プリンタがネットワーク ユーザーには非表示になっているかどうかが示されます。

Returns:

  • (boolean)

    Hidden



456
457
458
# File 'lib/Win32_Printer.rb', line 456

def 
  @Hidden
end

- (uint32) HorizontalResolution (readonly)

プリンタの水平方向の解像度 (ピクセル/インチ) です。

Returns:

  • (uint32)

    HorizontalResolution



461
462
463
# File 'lib/Win32_Printer.rb', line 461

def HorizontalResolution
  @HorizontalResolution
end

- (datetime) InstallDate (readonly)

InstallDate プロパティは、オブジェクトがインストールされた日時を示す値です。

 

Returns:

  • (datetime)

    InstallDate



467
468
469
# File 'lib/Win32_Printer.rb', line 467

def InstallDate
  @InstallDate
end

- (uint32) JobCountSinceLastReset (readonly)

前回のリセット後に処理された印刷ジョブです。

 

Returns:

  • (uint32)

    JobCountSinceLastReset



473
474
475
# File 'lib/Win32_Printer.rb', line 473

def JobCountSinceLastReset
  @JobCountSinceLastReset
end

- (boolean) KeepPrintedJobs

KeepPrintedJobs プロパティにより、ジョブの終了後に印刷スプーラがジョブを削除するべきではないかどうかを示します。

Returns:

  • (boolean)

    KeepPrintedJobs



478
479
480
# File 'lib/Win32_Printer.rb', line 478

def KeepPrintedJobs
  @KeepPrintedJobs
end

- (uint16) LanguagesSupported (readonly)

サポートされている印刷言語を示す配列です。

Returns:

  • (uint16)

    LanguagesSupported



483
484
485
# File 'lib/Win32_Printer.rb', line 483

def LanguagesSupported
  @LanguagesSupported
end

- (uint32) LastErrorCode (readonly)

論理デバイスで報告されたエラー コードが LastErrorCode によってキャプチャされます。

Returns:

  • (uint32)

    LastErrorCode



488
489
490
# File 'lib/Win32_Printer.rb', line 488

def LastErrorCode
  @LastErrorCode
end

- (boolean) Local

Local プロパティにより、プリンタがネットワークに接続されているかどうかが示されます。

  

Returns:

  • (boolean)

    Local



495
496
497
# File 'lib/Win32_Printer.rb', line 495

def Local
  @Local
end

- (string) Location

場所
プロパティにより、プリンタの物理的場所が指定されます。
 

Returns:

  • (string)

    Location



502
503
504
# File 'lib/Win32_Printer.rb', line 502

def Location
  @Location
end

- (uint16) MarkingTechnology (readonly)

プリンタで使用されているマークされているテクノロジです。

Returns:

  • (uint16)

    MarkingTechnology



507
508
509
# File 'lib/Win32_Printer.rb', line 507

def MarkingTechnology
  @MarkingTechnology
end

- (uint32) MaxCopies (readonly)

単一のジョブでプリンタから印刷できる最大部数です。

Returns:

  • (uint32)

    MaxCopies



512
513
514
# File 'lib/Win32_Printer.rb', line 512

def MaxCopies
  @MaxCopies
end

- (uint32) MaxNumberUp (readonly)

プリンタが単一のメディア シートに送ることのできる印刷 - ストリームの最大部数です。

Returns:

  • (uint32)

    MaxNumberUp



517
518
519
# File 'lib/Win32_Printer.rb', line 517

def MaxNumberUp
  @MaxNumberUp
end

- (uint32) MaxSizeSupported (readonly)

プリンタが KB の単位で受け入れる最大ジョブ (バイト ストリームとしての)を指定します。

 

Returns:

  • (uint32)

    MaxSizeSupported



523
524
525
# File 'lib/Win32_Printer.rb', line 523

def MaxSizeSupported
  @MaxSizeSupported
end

- (string) MimeTypesSupported (readonly)

プリンタにサポートされている MIME の種類の詳細な情報を提供する自由形式の文字列の配列です。

 

Returns:

  • (string)

    MimeTypesSupported



529
530
531
# File 'lib/Win32_Printer.rb', line 529

def MimeTypesSupported
  @MimeTypesSupported
end

- (string) Name (readonly)

Name プロパティで、オブジェクトを認識するラベルを定義します。

 

Returns:

  • (string)

    Name



535
536
537
# File 'lib/Win32_Printer.rb', line 535

def Name
  @Name
end

- (string) NaturalLanguagesSupported (readonly)

管理情報の出力用のプリンタに使用されている文字列に利用可能な言語を示します。

 

Returns:

  • (string)

    NaturalLanguagesSupported



542
543
544
# File 'lib/Win32_Printer.rb', line 542

def NaturalLanguagesSupported
  @NaturalLanguagesSupported
end

- (boolean) Network

Network プロパティにより、プリンタがネットワークのプリンタであるかどうかが示されます。

Returns:

  • (boolean)

    Network



547
548
549
# File 'lib/Win32_Printer.rb', line 547

def Network
  @Network
end

- (uint16) PaperSizesSupported (readonly)

用紙の種類を示す整数の配列です。

Returns:

  • (uint16)

    PaperSizesSupported



552
553
554
# File 'lib/Win32_Printer.rb', line 552

def PaperSizesSupported
  @PaperSizesSupported
end

- (string) PaperTypesAvailable (readonly)

プリンタで現在利用可能な用紙の種類を指定する自由形式の文字列の配列です。

 

Returns:

  • (string)

    PaperTypesAvailable



560
561
562
# File 'lib/Win32_Printer.rb', line 560

def PaperTypesAvailable
  @PaperTypesAvailable
end

- (string) Parameters

Parameters プロパティにより、プリント プロセッサのオプショナル パラメータが指定されます。

 

Returns:

  • (string)

    Parameters



567
568
569
# File 'lib/Win32_Printer.rb', line 567

def Parameters
  @Parameters
end

- (string) PNPDeviceID (readonly)

論理デバイスの Win32 プラグ アンド プレイ デバイス ID を示します。

 

Returns:

  • (string)

    PNPDeviceID



573
574
575
# File 'lib/Win32_Printer.rb', line 573

def PNPDeviceID
  @PNPDeviceID
end

- (string) PortName

PortName プロパティは、プリンタにデータを送信するのに使用されるポートを示します。

 

Returns:

  • (string)

    PortName



582
583
584
# File 'lib/Win32_Printer.rb', line 582

def PortName
  @PortName
end

- (uint16) PowerManagementCapabilities (readonly)

論理デバイスの特定の電源関連機能を示します。

 0="不明"

Returns:

  • (uint16)

    PowerManagementCapabilities



593
594
595
# File 'lib/Win32_Printer.rb', line 593

def PowerManagementCapabilities
  @PowerManagementCapabilities
end

- (boolean) PowerManagementSupported (readonly)

デバイスを電源管理できることを示すブール値です - 例、省電力状態にする。

 

Returns:

  • (boolean)

    PowerManagementSupported



601
602
603
# File 'lib/Win32_Printer.rb', line 601

def PowerManagementSupported
  @PowerManagementSupported
end

- (string) PrinterPaperNames (readonly)

PrinterPaperNames プロパティは、プリンタによってサポートされる用紙サイズの一覧を示します。

 

Returns:

  • (string)

    PrinterPaperNames



609
610
611
# File 'lib/Win32_Printer.rb', line 609

def PrinterPaperNames
  @PrinterPaperNames
end

- (uint32) PrinterState (readonly)

このプロパティは、プリンタの状態およびプリンタのエラーの状態をさらに明確に示す PrinterStatus、DetectedErrorState、および ErrorInformation CIM プロパティのために使用されていません。

 PrinterState 

Returns:

  • (uint32)

    PrinterState



615
616
617
# File 'lib/Win32_Printer.rb', line 615

def PrinterState
  @PrinterState
end

- (uint16) PrinterStatus (readonly)

論理デバイスの Availability プロパティで指定されたプリンタの状態よりも詳細な情報です。

 

Returns:

  • (uint16)

    PrinterStatus



621
622
623
# File 'lib/Win32_Printer.rb', line 621

def PrinterStatus
  @PrinterStatus
end

- (string) PrintJobDataType

PrintJobDataType プロパティにより、印刷ジョブに使用される既定のデータの種類が示されます。

Returns:

  • (string)

    PrintJobDataType



626
627
628
# File 'lib/Win32_Printer.rb', line 626

def PrintJobDataType
  @PrintJobDataType
end

- (string) PrintProcessor

PrintProcessor プロパティにより、印刷ジョブを処理する印刷スプーラの名前が指定されます。

 

Returns:

  • (string)

    PrintProcessor



633
634
635
# File 'lib/Win32_Printer.rb', line 633

def PrintProcessor
  @PrintProcessor
end

- (uint32) Priority

Priority プロパティにより、プリンタの優先順位が指定されます。

 

Returns:

  • (uint32)

    Priority



639
640
641
# File 'lib/Win32_Printer.rb', line 639

def Priority
  @Priority
end

- (boolean) Published

Published プロパティにより、ネットワーク ディレクトリ サービスでプリンタが公開されているかどうか示されます。

Returns:

  • (boolean)

    Published



644
645
646
# File 'lib/Win32_Printer.rb', line 644

def Published
  @Published
end

- (boolean) Queued

Queued プロパティにより、プリンタが印刷ジョブがバッファしキューに登録するかどうかが示されます。

Returns:

  • (boolean)

    Queued



649
650
651
# File 'lib/Win32_Printer.rb', line 649

def Queued
  @Queued
end

- (boolean) RawOnly

RawOnly プロパティにより、プリンタが未処理データのみをスプールするかどうかを示します。

Returns:

  • (boolean)

    RawOnly



654
655
656
# File 'lib/Win32_Printer.rb', line 654

def RawOnly
  @RawOnly
end

- (string) SeparatorFile

SeparatorFile プロパティにより、区切りページを作成するのに使われるファイルの名前が指定されます。

 

Returns:

  • (string)

    SeparatorFile



660
661
662
# File 'lib/Win32_Printer.rb', line 660

def SeparatorFile
  @SeparatorFile
end

- (string) ServerName (readonly)

ServerName プロパティは、プリンタを制御するサーバーを識別します。

 

Returns:

  • (string)

    ServerName



667
668
669
# File 'lib/Win32_Printer.rb', line 667

def ServerName
  @ServerName
end

- (boolean) Shared

Shared プロパティにより、プリンタが共有されたネットワーク リソースとして利用可能かどうかが示されます。

Returns:

  • (boolean)

    Shared



672
673
674
# File 'lib/Win32_Printer.rb', line 672

def Shared
  @Shared
end

- (string) ShareName

ShareName プロパティは、Win32 印刷装置の共有名を示します。

 

Returns:

  • (string)

    ShareName



679
680
681
# File 'lib/Win32_Printer.rb', line 679

def ShareName
  @ShareName
end

- (boolean) SpoolEnabled (readonly)

SpoolEnabled プロパティは、このプリンタでスプールが有効かどうかを示します。

 

Returns:

  • (boolean)

    SpoolEnabled



689
690
691
# File 'lib/Win32_Printer.rb', line 689

def SpoolEnabled
  @SpoolEnabled
end

- (datetime) StartTime

StartTime プロパティにより、プリンタが印刷ジョブを実行できる最も早い時間 (プリンタが限られた時間でのみ印刷するように設定されている場合) が指定されます。

 

Returns:

  • (datetime)

    StartTime



695
696
697
# File 'lib/Win32_Printer.rb', line 695

def StartTime
  @StartTime
end

- (string) Status (readonly)

Status プロパティはオブジェクトの現在の状態を示す文字列です。

 

Returns:

  • (string)

    Status



708
709
710
# File 'lib/Win32_Printer.rb', line 708

def Status
  @Status
end

- (uint16) StatusInfo (readonly)

StatusInfo は、論理デバイスが有効 (値 = 3)、無効 (値 = 4) またはその他 (1) または不明 (2) 状態であるかどうかを示す文字列です。

 

Returns:

  • (uint16)

    StatusInfo



714
715
716
# File 'lib/Win32_Printer.rb', line 714

def StatusInfo
  @StatusInfo
end

- (string) SystemCreationClassName (readonly)

スコーピング システムの CreationClassName です。

Returns:

  • (string)

    SystemCreationClassName



720
721
722
# File 'lib/Win32_Printer.rb', line 720

def SystemCreationClassName
  @SystemCreationClassName
end

- (string) SystemName (readonly)

スコーピング システムの名前です。

Returns:

  • (string)

    SystemName



725
726
727
# File 'lib/Win32_Printer.rb', line 725

def SystemName
  @SystemName
end

- (datetime) TimeOfLastReset (readonly)

プリンタ デバイスの前回のリセットの時刻です。

Returns:

  • (datetime)

    TimeOfLastReset



730
731
732
# File 'lib/Win32_Printer.rb', line 730

def TimeOfLastReset
  @TimeOfLastReset
end

- (datetime) UntilTime

UntilTime プロパティにより、プリンタが印刷ジョブを実行できる最新の時間が指定されます (プリンタが印刷を実行する時間が制限されている場合)。

 

Returns:

  • (datetime)

    UntilTime



736
737
738
# File 'lib/Win32_Printer.rb', line 736

def UntilTime
  @UntilTime
end

- (uint32) VerticalResolution (readonly)

プリンタの垂直方向の解像度 (ピクセル/インチ) です。

Returns:

  • (uint32)

    VerticalResolution



741
742
743
# File 'lib/Win32_Printer.rb', line 741

def VerticalResolution
  @VerticalResolution
end

- (boolean) WorkOffline

WorkOffline プロパティにより、プリンタがオフラインの場合にコンピュータで印刷ジョブのキュー登録を行うかどうかを示します。

Returns:

  • (boolean)

    WorkOffline



746
747
748
# File 'lib/Win32_Printer.rb', line 746

def WorkOffline
  @WorkOffline
end

Instance Method Details

- (uint32) AddPrinterConnection(Name)

AddPrinterConnection メソッドは、ネットワークにあるプリンタへの接続を提供し、そのプリンタをコンピュータ システムの利用可能なプリンタの一覧に追加します。 成功の場合、アプリケーションがこのプリンタを印刷ジョブに使用できるようになります。 成功しなければ、プリンタはインストールされません。 メソッドは次の値を返すことができます: 0 - 成功です。

5 - アクセスが拒否されました。

1801 - プリンタ名が無効です。

1930 - 互換性のないプリンタ ドライバです。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Parameters:

  • (string, #read) Name

    Name パラメータにより、プリンタのフレンドリ名が指定されます。 名前が既にプリンタによって設定されている場合は、上書きされる可能性があります。

Returns:

  • (uint32)


83
84
# File 'lib/Win32_Printer.rb', line 83

def AddPrinterConnection Name
end

- (uint32) CancelAllJobs

CancelAllJobs メソッドは、現在印刷中のジョブを含むすべての印刷ジョブをキャンセルし、印刷キューから削除します。 メソッドは次の値を返すことができます: 0 - 成功です。

5 - アクセスが拒否されました。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Returns:

  • (uint32)


62
63
# File 'lib/Win32_Printer.rb', line 62

def CancelAllJobs 
end

- (uint32) Pause

Pause メソッドは印刷キューを一時停止します。 印刷キューが再開されるまでは、これ以上ジョブを印刷できません。 メソッドは次の値を返すことができます: 0 - 成功です。

5 - アクセスが拒否されました。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Returns:

  • (uint32)


38
39
# File 'lib/Win32_Printer.rb', line 38

def Pause 
end

- (uint32) PrintTestPage

PrintTestPage メソッドはテスト ページを印刷します。 メソッドは次の値を返すことができます: 0 - 成功です。

5 - アクセスが拒否されました。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Returns:

  • (uint32)


111
112
# File 'lib/Win32_Printer.rb', line 111

def PrintTestPage 
end

- (uint32) RenamePrinter(NewPrinterName)

RenamePrinter メソッドはプリンタの名前を変更します。 メソッドは次の値を返すことができます: 0 - 成功です。

5 - アクセスが拒否されました。

1801 - プリンタ名が無効です。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Parameters:

  • (string, #read) NewPrinterName

    NewPrinterName パラメータにより、新しいプリンタ名が指定されます。

Returns:

  • (uint32)


99
100
# File 'lib/Win32_Printer.rb', line 99

def RenamePrinter NewPrinterName
end

- (uint32) Reset

論理デバイスのリセットを要求します。 要求が正常に実行された場合、返される値は 0 で、要求がサポートされない場合は 1 です。 また、エラーが発生した場合は、ほかの値となります。

Returns:

  • (uint32)


25
26
# File 'lib/Win32_Printer.rb', line 25

def Reset 
end

- (uint32) Resume

Resume メソッドは一時停止された印刷キューを再開します。 メソッドは次の値を返すことができます: 0 - 成功です。

5 - アクセスが拒否されました。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Returns:

  • (uint32)


50
51
# File 'lib/Win32_Printer.rb', line 50

def Resume 
end

- (uint32) SetDefaultPrinter

SetDefaultPrinter メソッドは、メソッドを実効したユーザー用に通常使うプリンタにプリンタを設定します。 メソッドは次の値を返すことができます: 0 - 成功です。

その他 - 上の一覧以外の整数値については Win32 エラー コードのドキュメントを参照してください。

Returns:

  • (uint32)


121
122
# File 'lib/Win32_Printer.rb', line 121

def SetDefaultPrinter 
end

- (uint32) SetPowerState(PowerState, Time)

SetPowerState により、論理デバイスの電源状態およびデバイスがいつその状態に入るかが定義されます。 電源状態は、PowerState パラメータを次の整数値の 1 つに設定することによって指定されます: 1="通常の電力"、2="省電力- 低電力モード"、3="省電力 - スタンバイ"、4="省電力 - その他"、5="電源サイクル" または 6="電源オフ"。 時間パラメータ (5 の "Power Cycle" を除くすべての状態の変更用) は、通常の日付値または間隔値 (メソッド実行の受信時に間隔が開始される) のどちらかにいつ電源状態が設定される必要があるかを示します。 PowerState パラメータが 5 ("Power Cycle") であるとき、時間パラメータはいつデバイスが再度電源オンになるかを示します。 直ちに電源をオフにします。 成功の場合、SetPowerState は 0 を返し、指定された PowerState および要求時間がサポートされていない場合は、1 を返し、ほかのエラーが発生する場合はほかの値が返されます。 サブクラスでは、可能な返信コードのセットはメソッド上の ValueMap 修飾子を使って指定することも可能です。

 ValueMap 

値の配置修飾子としてサブクラスで指定される場合もあります。

Parameters:

  • (uint16, #read) PowerState
  • (datetime, #read) Time

Returns:

  • (uint32)


17
18
# File 'lib/Win32_Printer.rb', line 17

def SetPowerState PowerState, Time
end