Search Options

Results per page
Sort
Preferred Languages
Advance

Results 951 - 960 of 1,622 for Length (0.05 sec)

  1. internal/ringbuffer/README.md

    # Usage
    
    ```go
    package main
    
    import (
    	"fmt"
    
    	"github.com/smallnest/ringbuffer"
    )
    
    func main() {
    	rb := ringbuffer.New(1024)
    
    	// write
    	rb.Write([]byte("abcd"))
    	fmt.Println(rb.Length())
    	fmt.Println(rb.Free())
    
    	// read
    	buf := make([]byte, 4)
    	rb.Read(buf)
    	fmt.Println(string(buf))
    }
    ```
    
    It is possible to use an existing buffer with by replacing `New` with `NewBuffer`.
    
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Wed May 15 00:11:04 UTC 2024
    - 2.1K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/collect/SetsTest.java

                      @Override
                      protected Set<AnEnum> create(AnEnum[] elements) {
                        AnEnum[] otherElements = new AnEnum[elements.length - 1];
                        arraycopy(elements, 1, otherElements, 0, otherElements.length);
                        return Sets.immutableEnumSet(elements[0], otherElements);
                      }
                    })
                .named("Sets.immutableEnumSet")
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 48.6K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/collect/TreeMultisetTest.java

      }
    
      private static final Comparator<String> DEGENERATE_COMPARATOR =
          new Comparator<String>() {
            @Override
            public int compare(String o1, String o2) {
              return o1.length() - o2.length();
            }
          };
    
      /** Test a TreeMultiset with a comparator that can return 0 when comparing unequal values. */
      public void testDegenerateComparator() throws Exception {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Sat Oct 19 00:05:46 UTC 2024
    - 12.9K bytes
    - Viewed (0)
  4. guava-testlib/src/com/google/common/collect/testing/TestsForSetsInJavaUtil.java

        return SetTestSuiteBuilder.using(
                new TestEnumSetGenerator() {
                  @Override
                  public Set<AnEnum> create(AnEnum[] elements) {
                    return (elements.length == 0)
                        ? EnumSet.noneOf(AnEnum.class)
                        : EnumSet.copyOf(MinimalCollection.of(elements));
                  }
                })
            .named("EnumSet")
            .withFeatures(
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 30 16:15:19 UTC 2024
    - 19.8K bytes
    - Viewed (0)
  5. cmd/naughty-disk_test.go

    }
    
    func (d *naughtyDisk) ReadFileStream(ctx context.Context, volume, path string, offset, length int64) (io.ReadCloser, error) {
    	if err := d.calcError(); err != nil {
    		return nil, err
    	}
    	return d.disk.ReadFileStream(ctx, volume, path, offset, length)
    }
    
    func (d *naughtyDisk) CreateFile(ctx context.Context, origvolume, volume, path string, size int64, reader io.Reader) error {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Aug 12 08:38:15 UTC 2024
    - 10.1K bytes
    - Viewed (0)
  6. src/main/java/org/codelibs/fess/helper/LabelTypeHelper.java

            final Set<String> roleSet = ComponentUtil.getRoleQueryHelper().build(searchRequestType);
            if (roleSet.isEmpty()) {
                for (final LabelTypeItem item : labelList) {
                    if (item.getPermissions().length == 0) {
                        final Map<String, String> map = new HashMap<>(2);
                        map.put(Constants.ITEM_LABEL, item.getLabel());
                        map.put(Constants.ITEM_VALUE, item.getValue());
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Fri Oct 11 21:20:39 UTC 2024
    - 11.7K bytes
    - Viewed (0)
  7. src/main/java/org/codelibs/fess/helper/RoleQueryHelper.java

                    return;
                }
            }
    
            if (logger.isDebugEnabled()) {
                logger.debug("role: original: {}, decrypto: {}", value, rolesStr);
            }
    
            if (valueSeparator.length() > 0) {
                final String[] values = rolesStr.split(valueSeparator);
                if (maxAge > 0) {
                    try {
                        final long time = getCurrentTime() / 1000 - Long.parseLong(values[0]);
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Jul 25 01:48:41 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  8. src/main/java/org/codelibs/fess/app/web/search/SearchAction.java

                    RenderDataUtil.register(data, "relatedContents", relatedContents);
                    final String[] relatedQueries = relatedQueryHelper.getRelatedQueries(form.getQuery());
                    if (relatedQueries.length > 0) {
                        RenderDataUtil.register(data, "relatedQueries", relatedQueries);
                    }
                });
            } catch (final InvalidQueryException e) {
                if (logger.isDebugEnabled()) {
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Thu Feb 22 01:53:18 UTC 2024
    - 12.3K bytes
    - Viewed (0)
  9. src/test/java/jcifs/tests/FileAttributesTest.java

                    throw e;
                }
            }
        }
    
    
        @Test
        public void testShareSize () throws IOException {
            try ( SmbResource f = getDefaultShareRoot() ) {
                long l = f.length();
                Assume.assumeTrue("No share size reported", l != 0);
            }
        }
    
    
        @Test
        public void testShareFreeSize () throws IOException {
    Registered: Sun Nov 03 00:10:13 UTC 2024
    - Last Modified: Thu Jan 05 13:09:03 UTC 2023
    - 12.3K bytes
    - Viewed (0)
  10. src/main/java/org/codelibs/fess/crawler/util/FieldConfigs.java

                    if ("cache".equalsIgnoreCase(value)) {
                        return true;
                    }
                }
                // backward compatibility
                if (values.length == 1 && Constants.TRUE.equalsIgnoreCase(values[0])) {
                    return true;
                }
                return false;
            }
    
            public boolean isOverwrite() {
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Fri Oct 11 21:11:58 UTC 2024
    - 2.3K bytes
    - Viewed (0)
Back to top