Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 21 for getOption (0.05 sec)

  1. src/test/java/jcifs/dcerpc/DcerpcPipeHandleTest.java

            @DisplayName("Should generate correct pipe URL with address option")
            void testMakePipeUrl_WithAddressOption() throws Exception {
                lenient().when(mockDcerpcBinding.getOption("server")).thenReturn(null);
                when(mockDcerpcBinding.getOption("address")).thenReturn("192.168.1.1");
                DcerpcPipeHandle handle = createMockedDcerpcPipeHandle();
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 21K bytes
    - Viewed (0)
  2. src/test/java/jcifs/dcerpc/DcerpcBindingTest.java

            dcerpcBinding.setOption("connect", "80");
            assertEquals("80", dcerpcBinding.getOption("connect"), "Should return the set option value.");
        }
    
        @Test
        void testGetOptionNonExistent() {
            assertNull(dcerpcBinding.getOption("nonExistent"), "Should return null for a non-existent option.");
        }
    
        @Test
        void testToStringWithoutOptionsAndEndpoint() {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 8.5K bytes
    - Viewed (0)
  3. src/main/java/jcifs/smb1/dcerpc/DcerpcPipeHandle.java

            String params = "", server, address;
            server = (String) binding.getOption("server");
            if (server != null) {
                params += "&server=" + server;
            }
            address = (String) binding.getOption("address");
            if (server != null) {
                params += "&address=" + address;
            }
            if (params.length() > 0) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 4.5K bytes
    - Viewed (0)
  4. src/main/java/jcifs/dcerpc/DcerpcPipeHandle.java

            String params = "";
            final String server = (String) binding.getOption("server");
            if (server != null) {
                params += "&server=" + server;
            }
            final String address = (String) binding.getOption("address");
            if (address != null) {
                params += "&address=" + address;
            }
            if (params.length() > 0) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 5.6K bytes
    - Viewed (0)
  5. src/main/java/jcifs/dcerpc/DcerpcBinding.java

            }
            if (this.options == null) {
                this.options = new HashMap<>();
            }
            this.options.put(key, val);
        }
    
        Object getOption(final String key) {
            if (key.equals("endpoint")) {
                return this.endpoint;
            }
            if (this.options != null) {
                return this.options.get(key);
            }
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 5K bytes
    - Viewed (0)
  6. src/main/java/jcifs/smb1/dcerpc/DcerpcBinding.java

                throw new DcerpcException("Bad endpoint: " + endpoint);
            }
            if (options == null) {
                options = new HashMap();
            }
            options.put(key, val);
        }
    
        Object getOption(final String key) {
            if (key.equals("endpoint")) {
                return endpoint;
            }
            if (options != null) {
                return options.get(key);
            }
            return null;
        }
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 3.8K bytes
    - Viewed (0)
  7. src/test/java/jcifs/internal/NotifyResponseTest.java

            assertEquals(FileNotifyInformation.FILE_ACTION_ADDED, result.get(0).getAction());
            assertEquals(FileNotifyInformation.FILE_ACTION_REMOVED, result.get(1).getAction());
            assertEquals(FileNotifyInformation.FILE_ACTION_MODIFIED, result.get(2).getAction());
            assertEquals(FileNotifyInformation.FILE_ACTION_RENAMED_OLD_NAME, result.get(3).getAction());
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 21.2K bytes
    - Viewed (0)
  8. src/test/java/jcifs/FileNotifyInformationTest.java

        class InterfaceMethodsTests {
    
            @Test
            @DisplayName("Test getAction method with mock")
            void testGetAction() {
                // Setup mock behavior
                when(mockFileNotifyInfo.getAction()).thenReturn(FileNotifyInformation.FILE_ACTION_ADDED);
    
                // Test
                int action = mockFileNotifyInfo.getAction();
    
                // Verify
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.1K bytes
    - Viewed (0)
  9. src/test/java/jcifs/SmbWatchHandleTest.java

            when(fileNotifyInfo1.getAction()).thenReturn(FileNotifyInformation.FILE_ACTION_ADDED);
            when(fileNotifyInfo1.getFileName()).thenReturn("newfile.txt");
    
            when(fileNotifyInfo2.getAction()).thenReturn(FileNotifyInformation.FILE_ACTION_MODIFIED);
            when(fileNotifyInfo2.getFileName()).thenReturn("existingfile.txt");
    
            when(fileNotifyInfo3.getAction()).thenReturn(FileNotifyInformation.FILE_ACTION_REMOVED);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 13.2K bytes
    - Viewed (0)
  10. src/test/java/jcifs/internal/smb1/trans/nt/FileNotifyInformationImplTest.java

        }
    
        @Test
        @DisplayName("Test default constructor creates instance with null values")
        void testDefaultConstructor() {
            assertNotNull(notifyInfo);
            assertEquals(0, notifyInfo.getAction());
            assertNull(notifyInfo.getFileName());
            assertEquals(0, notifyInfo.getNextEntryOffset());
        }
    
        @Test
        @DisplayName("Test constructor with buffer decodes correctly")
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 13.1K bytes
    - Viewed (0)
Back to top