Skip to content
Permalink
Browse files

21368: Add MemoryStore missing attributes

#isReadable:, #isRegular:, #isWritable, #permissions:
  • Loading branch information
akgrant committed Jul 6, 2018
1 parent ca38f5f commit 90999eade4b96e3070a568d5baf699f5490f4789
Showing with 32 additions and 0 deletions.
  1. +32 −0 src/FileSystem-Memory/MemoryStore.class.st
@@ -281,6 +281,30 @@ MemoryStore >> isMemoryFileSystem [
^ true
]

{ #category : #accessing }
MemoryStore >> isReadable: aPath [
"Answer a boolean indicating whether the entry at aPath is readable.
Memory store doesn't have access controls, all entries are readable."

^true
]

{ #category : #accessing }
MemoryStore >> isRegular: aPath [
"Answer a boolean indicating whether the entry at aPath is writable.
Memory store only supports regular files."

^self isFile: aPath
]

{ #category : #accessing }
MemoryStore >> isWritable: aPath [
"Answer a boolean indicating whether the entry at aPath is writable.
Memory store doesn't have access controls, all entries are writable."

^true
]

{ #category : #accessing }
MemoryStore >> modificationTimeOf: aPath [

@@ -328,6 +352,14 @@ MemoryStore >> openFileStream: path writable: isWriteStream [
ifFalse: [ entry readStream ]
]

{ #category : #accessing }
MemoryStore >> permissions: aPath [
"Answer the FileSystemPermission's for aPath.
Memory Store doesn't implement access controls."

^FileSystemPermission posixPermissions: 8r777
]

{ #category : #public }
MemoryStore >> rename: sourcePath to: destinationPath [
| sourceEntry destinationParentEntry newName |

0 comments on commit 90999ea

Please sign in to comment.
You can’t perform that action at this time.