Skip navigation links
JNA API 5.13.0
com.sun.jna.platform.unix.solaris

Class Kstat2.Kstat2Handle

  • All Implemented Interfaces:
    NativeMapped
    Enclosing interface:
    Kstat2


    public static class Kstat2.Kstat2Handle
    extends PointerType
    Opaque kstat handle.
    • Constructor Detail

      • Kstat2Handle

        public Kstat2Handle(Kstat2.Kstat2MatcherList matchers)
        Instantiates and opens a new Kstat2Handle filtered with the provided matcher. Convenience method for Kstat2.kstat2_open(PointerByReference, Kstat2MatcherList).
        Parameters:
        matchers - Only kstats that match one or more of the provided matchers will be available. If a NULL or empty matcher list is provided, all of the system's kstats will be available. Restricting the number of kstats available will improve performance and reduce the memory footprint.
    • Method Detail

      • update

        public int update()
        Convenience method for Kstat2.kstat2_update(Kstat2Handle) that synchronises the user's view with that of the kernel. The kernel may at any point add or remove kstats, causing the user's view of the available kstats to become out of date.
        Returns:
        Upon successful completion, returns a int value of Kstat2.KSTAT2_S_OK. If an error occurs a value other than KSTAT2_S_OK is returned.
      • close

        public int close()
        Convenience method for Kstat2.kstat2_close(PointerByReference). After use, the kstat handle should be closed to reclaim the handles and memory that it allocated on open.
        Returns:
        Upon successful completion, returns a int value of Kstat2.KSTAT2_S_OK. If an error occurs a value other than KSTAT2_S_OK is returned.
JNA API 5.13.0

Copyright © 2007-2018 Timothy Wall. All Rights Reserved.