Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 26 for getTree (1.04 sec)

  1. src/main/java/jcifs/smb/SmbTreeConnection.java

            return this.ctx.getConfig();
        }
    
        private synchronized SmbTreeImpl getTree() {
            final SmbTreeImpl t = this.tree;
            if (t != null) {
                return t.acquire(false);
            }
            if (this.delegate != null) {
                this.tree = this.delegate.getTree();
                return this.tree;
            }
            return t;
        }
    
        /**
         * @return
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 30 05:58:03 UTC 2025
    - 30.4K bytes
    - Viewed (0)
  2. src/test/java/jcifs/smb/SmbPipeInputStreamTest.java

            SmbPipeInputStream stream = newStreamWithMinimalStubs(true);
    
            // Arrange mocks for available()
            when(handle.ensureOpen()).thenReturn(fd);
            when(fd.getTree()).thenReturn(tree);
            when(tree.isSMB2()).thenReturn(true);
            when(tree.getConfig()).thenReturn(config);
            when(config.getTransactionBufferSize()).thenReturn(65535);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 9.9K bytes
    - Viewed (0)
  3. src/test/java/jcifs/smb/SmbWatchHandleImplTest.java

        // Prepare SMB2 flow with a given response
        private void setupSmb2(NotifyResponse resp, byte[] fileId) throws Exception {
            when(handle.isValid()).thenReturn(true);
            when(handle.getTree()).thenReturn(tree);
            when(tree.isSMB2()).thenReturn(true);
            when(tree.getConfig()).thenReturn(mock(Configuration.class));
            when(handle.getFileId()).thenReturn(fileId);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.5K bytes
    - Viewed (0)
  4. src/test/java/jcifs/smb/SmbFileHandleImplTest.java

        }
    
        @Test
        @DisplayName("getTree() acquires and returns same tree instance")
        void getTree_acquiresAndReturnsTree() {
            when(cfg.isTraceResourceUsage()).thenReturn(false);
            stubValidTree(7L, true, true);
    
            SmbFileHandleImpl h = new SmbFileHandleImpl(cfg, 123, tree, "//server/share", 0, 0, 0, 0, 0L);
    
            SmbTreeHandleImpl t1 = h.getTree();
            SmbTreeHandleImpl t2 = h.getTree();
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.3K bytes
    - Viewed (0)
  5. src/test/java/jcifs/smb/SmbPipeHandleImplTest.java

            when(fileHandle.acquire()).thenReturn(fileHandle);
            when(fileHandle.isValid()).thenReturn(true);
            when(fileHandle.getTree()).thenReturn(tree);
    
            // Initially not open (isStale returns false when handle is null, not true)
            assertFalse(target.isOpen());
            assertFalse(target.isStale());
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.7K bytes
    - Viewed (0)
  6. src/test/java/jcifs/smb/SmbPipeHandleInternalTest.java

            when(fh.acquire()).thenReturn(fh);
            lenient().when(fh.isValid()).thenReturn(true);
            lenient().when(fh.getTree()).thenReturn(tree);
            when(fh.getFileId()).thenReturn(new byte[16]);
    
            // Setup for ioctl request
            when(tree.send(any(Smb2IoctlRequest.class), eq(RequestParam.NO_RETRY))).thenReturn(ioctlResp);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 16.7K bytes
    - Viewed (0)
  7. src/test/java/jcifs/smb/SmbRandomAccessFileTest.java

            when(file.openUnshared(anyInt(), anyInt(), anyInt(), anyInt(), anyInt())).thenReturn(fh);
            when(fh.acquire()).thenReturn(fh);
            when(fh.isValid()).thenReturn(true);
            when(fh.getTree()).thenReturn(tree);
            when(fh.getFileId()).thenReturn(new byte[16]);
            when(fh.getFid()).thenReturn(1);
    
            // build via package-private constructor to control unshared flag
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.1K bytes
    - Viewed (0)
  8. src/main/java/jcifs/smb/SmbRandomAccessFile.java

            if (len <= 0) {
                return 0;
            }
            final long start = this.fp;
    
            try (SmbFileHandleImpl fh = ensureOpen(); SmbTreeHandleImpl th = fh.getTree()) {
    
                int r, n;
                final SmbComReadAndXResponse response = new SmbComReadAndXResponse(th.getConfig(), b, off);
                do {
                    r = len > this.readSize ? this.readSize : len;
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 18.8K bytes
    - Viewed (0)
  9. docs/smb3-features/02-persistent-handles-design.md

                    }
                    
                    // Send create request
                    Smb2CreateResponse response = (Smb2CreateResponse) 
                        file.getTree().send(createReq);
                    
                    if (response.isSuccess()) {
                        // Update file with new handle
                        file.setFileId(response.getFileId());
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 02:53:50 UTC 2025
    - 31.6K bytes
    - Viewed (0)
  10. src/main/java/jcifs/smb/SmbPipeHandleImpl.java

        @Override
        public int sendrecv(final byte[] buf, final int off, final int length, final byte[] inB, final int maxRecvSize) throws IOException {
            try (SmbFileHandleImpl fh = ensureOpen(); SmbTreeHandleImpl th = fh.getTree()) {
    
                if (th.isSMB2()) {
                    final Smb2IoctlRequest req =
                            new Smb2IoctlRequest(th.getConfig(), Smb2IoctlRequest.FSCTL_PIPE_TRANSCEIVE, fh.getFileId(), inB);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sun Aug 31 08:00:57 UTC 2025
    - 10.2K bytes
    - Viewed (0)
Back to top