Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 10 for TYPE_FILESYSTEM (0.08 sec)

  1. src/test/java/jcifs/smb/SmbFileInputStreamTest.java

                when(mockTree.getReceiveBufferSize()).thenReturn(0x200000);
                when(mockTree.getMaximumBufferSize()).thenReturn(0x200000);
    
                // Make TYPE_FILESYSTEM path, not named pipe
                when(mockFile.getType()).thenReturn(SmbConstants.TYPE_FILESYSTEM);
    
                // Capture the ReadAndX request; throw to short-circuit network
                doAnswer(inv -> {
                    throw new SmbException("short-circuit");
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 12.8K bytes
    - Viewed (0)
  2. src/test/java/jcifs/SmbConstantsTest.java

                    SmbConstants.DEFAULT_SHARING);
        }
    
        @Test
        @DisplayName("Should define SMB resource type constants")
        void testResourceTypeConstants() {
            assertEquals(0x01, SmbConstants.TYPE_FILESYSTEM);
            assertEquals(0x02, SmbConstants.TYPE_WORKGROUP);
            assertEquals(0x04, SmbConstants.TYPE_SERVER);
            assertEquals(0x08, SmbConstants.TYPE_SHARE);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.3K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/fscc/FileBothDirectoryInfoTest.java

            // Verify
            assertEquals("testfile.txt", fileBothDirectoryInfo.getName());
        }
    
        @Test
        @DisplayName("Test getType returns TYPE_FILESYSTEM")
        void testGetType() {
            assertEquals(SmbConstants.TYPE_FILESYSTEM, fileBothDirectoryInfo.getType());
        }
    
        @Test
        @DisplayName("Test getFileIndex returns correct value")
        void testGetFileIndex() throws SMBProtocolDecodingException {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 20.9K bytes
    - Viewed (0)
  4. src/test/java/jcifs/smb/SmbResourceLocatorImplTest.java

        @Test
        @DisplayName("Type detection covers filesystem/share/IPC/workgroup/server")
        void testGetType() throws Exception {
            // Filesystem when there is a path beyond share
            assertEquals(SmbConstants.TYPE_FILESYSTEM, locator("smb://server/share/path").getType());
    
            // Named pipe for IPC$ root
            assertEquals(SmbConstants.TYPE_NAMED_PIPE, locator("smb://server/IPC$/").getType());
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 17.6K bytes
    - Viewed (0)
  5. src/test/java/jcifs/SmbResourceTest.java

            @Test
            @DisplayName("getType should return valid SMB resource type")
            void testGetType() throws CIFSException {
                // Given
                int expectedType = 1; // Assuming TYPE_FILESYSTEM
                when(mockResource.getType()).thenReturn(expectedType);
    
                // When
                int type = mockResource.getType();
    
                // Then
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 35K bytes
    - Viewed (0)
  6. src/main/java/jcifs/SmbConstants.java

        /**
         * Returned by {@link jcifs.SmbResource#getType()} if the resource this <code>SmbFile</code>
         * represents is a regular file or directory.
         */
        int TYPE_FILESYSTEM = 0x01;
        /**
         * Returned by {@link jcifs.SmbResource#getType()} if the resource this <code>SmbFile</code>
         * represents is a workgroup.
         */
        int TYPE_WORKGROUP = 0x02;
        /**
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 24 00:49:49 UTC 2025
    - 12.8K bytes
    - Viewed (0)
  7. src/main/java/jcifs/SmbResource.java

         *         itself.
         */
        String getName();
    
        /**
         * Returns type of of object this <code>SmbResource</code> represents.
         *
         * @return <code>TYPE_FILESYSTEM, TYPE_WORKGROUP, TYPE_SERVER, TYPE_SHARE,
         * TYPE_PRINTER, TYPE_NAMED_PIPE</code>, or <code>TYPE_COMM</code>.
         * @throws CIFSException if an error occurs accessing the resource
         */
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 28K bytes
    - Viewed (1)
  8. src/main/java/jcifs/smb/SmbFileOutputStream.java

                }
    
                int w;
                do {
                    final int blockSize = this.file.getType() == SmbConstants.TYPE_FILESYSTEM ? this.writeSizeFile : this.writeSize;
                    w = len > blockSize ? blockSize : len;
    
                    if (this.smb2) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 12.8K bytes
    - Viewed (0)
  9. src/main/java/jcifs/smb/SmbFileInputStream.java

                }
    
                final int type = this.file.getType();
                int r, n;
                final int blockSize = type == SmbConstants.TYPE_FILESYSTEM ? this.readSizeFile : this.readSize;
    
                // Optimization: Use larger block sizes for better performance
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 15.6K bytes
    - Viewed (0)
  10. src/main/java/jcifs/smb/SmbResourceLocatorImpl.java

         */
        @Override
        public int getType() throws CIFSException {
            if (this.type == 0) {
                if (getUNCPath().length() > 1) {
                    this.type = SmbConstants.TYPE_FILESYSTEM;
                } else if (getShare() != null) {
                    if (getShare().equals("IPC$")) {
                        this.type = SmbConstants.TYPE_NAMED_PIPE;
                    } else {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 23.6K bytes
    - Viewed (0)
Back to top