Reading Windows file summary properties (title, subject, author) in Java

后端 未结 2 760
一整个雨季
一整个雨季 2020-11-30 12:12

If you right-click on a file in Windows and select Properties, you can manage some properties in de Summary tab, such as Title, Subject and

相关标签:
2条回答
  • 2020-11-30 12:17

    That information is stored in an NTFS Alternate Data Stream named "♣SummaryInformation" - not sure if Java supports teh reading of ADS data via the colon notation.

    Update: Apparently this should work:

    FileInputStream in = new FileInputStream("test.txt:\u2663SummaryInformation");
    

    You'll have to figure out the format yourself.

    0 讨论(0)
  • 2020-11-30 12:43

    In Java 7 it may work, but until then you have to use a native dll, to get that information.

    0 讨论(0)
提交回复
热议问题