Cut out directroy string from filepath. If dir is null, then return length that require for store directory.
See Implementation
Cut out directroy string from filepath. If dir is null, then return length that require for store directory.