Coder Social home page Coder Social logo

Comments (4)

alphaleonis avatar alphaleonis commented on August 27, 2024

Comment by Yomodo from Thursday Jan 08, 2015 at 15:21 GMT


Great!

from alphafs.

alphaleonis avatar alphaleonis commented on August 27, 2024

Comment by alphaleonis from Saturday Jan 10, 2015 at 19:38 GMT


Fixed in #59... well, sort of.

from alphafs.

alphaleonis avatar alphaleonis commented on August 27, 2024

Comment by Yomodo from Saturday Jan 10, 2015 at 21:57 GMT


:( With the previous implementation, streams could also be added/removed to directories, are rare feature found on the net, but truly supported using Win32

This is a nifty feature because for example you can now also get the real size used by a folder,
because of alternate data streams.

FindFirstStreamW does not work on directories, that why I didn't use that.

from alphafs.

alphaleonis avatar alphaleonis commented on August 27, 2024

Comment by alphaleonis from Saturday Jan 10, 2015 at 22:12 GMT


Uhm, in my tests these work fine on directories as well. Also adding streams to directories works fine still.

For example:

// E:\Test is a directory
foreach (var stream in File.EnumerateAlternateDataStreams(@"\\?\E:\Test", PathFormat.LongFullPath))
{
   Console.WriteLine("Name: {0}", stream.StreamName);
}

using (FileStream fs = File.Open(@"\\?\E:\Test:myStream", System.IO.FileMode.Create, System.IO.FileAccess.Write, System.IO.FileShare.None, ExtendedFileAttributes.BackupSemantics, PathFormat.LongFullPath))
{
   fs.WriteByte(24);
}

If you want the other stream information, eg. non-data streams you can get those by using BackupFileStream. So no functionality has in that sense been removed.

from alphafs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.