Skip to content

Commit

Permalink
Merge pull request #354 from v-ahibr/javadocs
Browse files Browse the repository at this point in the history
Correct javadocs
  • Loading branch information
v-ahibr authored Jun 26, 2017
2 parents 11efe7e + 695436e commit ec418e0
Show file tree
Hide file tree
Showing 5 changed files with 47 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5593,11 +5593,11 @@ public void setEnablePrepareOnFirstPreparedStatementCall(boolean value) {
}

/**
* Returns the behavior for a specific connection instance. This setting controls how many outstanding prepared statement discard
* actions (sp_unprepare) can be outstanding per connection before a call to clean-up the outstanding handles on the server is executed.
* If the setting is <= 1 unprepare actions will be executed immedietely on prepared statement close. If it is set to >1 these calls will
* be batched together to avoid overhead of calling sp_unprepare too often.
* The default for this option can be changed by calling getDefaultServerPreparedStatementDiscardThreshold().
* Returns the behavior for a specific connection instance. This setting controls how many outstanding prepared statement discard actions
* (sp_unprepare) can be outstanding per connection before a call to clean-up the outstanding handles on the server is executed. If the setting is
* {@literal <=} 1, unprepare actions will be executed immedietely on prepared statement close. If it is set to {@literal >} 1, these calls
* will be batched together to avoid overhead of calling sp_unprepare too often. The default for this option can be changed by calling
* getDefaultServerPreparedStatementDiscardThreshold().
*
* @return Returns the current setting per the description.
*/
Expand Down Expand Up @@ -5708,7 +5708,8 @@ public boolean isStatementPoolingEnabled() {

/**
* Specifies the size of the prepared statement cache for this conection. A value less than 1 means no cache.
* @value The new cache size.
* @param value The new cache size.
*
*/
public void setStatementPoolingCacheSize(int value) {
if (value != this.statementPoolingCacheSize) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,11 @@ private void setPreparedStatementHandle(int handle) {
this.prepStmtHandle = handle;
}

/** The server handle for this prepared statement. If a value < 1 is returned no handle has been created.
/** The server handle for this prepared statement. If a value {@literal <} 1 is returned no handle has been created.
*
* @return
* Per the description.
* @throws SQLServerException when an error occurs
*/
public int getPreparedStatementHandle() throws SQLServerException {
checkClosed();
Expand Down Expand Up @@ -2963,11 +2964,13 @@ public final void setNull(int paramIndex,
/**
* Returns parameter metadata for the prepared statement.
*
* @forceRefresh
* @param forceRefresh:
* If true the cache will not be used to retrieve the metadata.
*
* @return
* Per the description.
*
* @throws SQLServerException when an error occurs
*/
public final ParameterMetaData getParameterMetaData(boolean forceRefresh) throws SQLServerException {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1479,6 +1479,8 @@ public Builder() {
*
* @param initialCapacity the initial capacity used to size the hash table
* to accommodate this many entries.
*
* @return Builder
* @throws IllegalArgumentException if the initialCapacity is negative
*/
public Builder<K, V> initialCapacity(int initialCapacity) {
Expand All @@ -1492,6 +1494,7 @@ public Builder<K, V> initialCapacity(int initialCapacity) {
* exceed it temporarily.
*
* @param capacity the weighted threshold to bound the map by
* @return Builder
* @throws IllegalArgumentException if the maximumWeightedCapacity is
* negative
*/
Expand All @@ -1508,6 +1511,7 @@ public Builder<K, V> maximumWeightedCapacity(long capacity) {
*
* @param concurrencyLevel the estimated number of concurrently updating
* threads
* @return Builder
* @throws IllegalArgumentException if the concurrencyLevel is less than or
* equal to zero
*/
Expand All @@ -1522,6 +1526,7 @@ public Builder<K, V> concurrencyLevel(int concurrencyLevel) {
* an entry is evicted.
*
* @param listener the object to forward evicted entries to
* @return Builder
* @throws NullPointerException if the listener is null
*/
public Builder<K, V> listener(EvictionListener<K, V> listener) {
Expand All @@ -1536,6 +1541,7 @@ public Builder<K, V> listener(EvictionListener<K, V> listener) {
* key-value pairs by giving each entry a weight of <tt>1</tt>.
*
* @param weigher the algorithm to determine a value's weight
* @return Builder
* @throws NullPointerException if the weigher is null
*/
public Builder<K, V> weigher(Weigher<? super V> weigher) {
Expand All @@ -1551,6 +1557,7 @@ public Builder<K, V> weigher(Weigher<? super V> weigher) {
* key-value pairs by giving each entry a weight of <tt>1</tt>.
*
* @param weigher the algorithm to determine a entry's weight
* @return Builder
* @throws NullPointerException if the weigher is null
*/
public Builder<K, V> weigher(EntryWeigher<? super K, ? super V> weigher) {
Expand All @@ -1563,6 +1570,7 @@ public Builder<K, V> weigher(EntryWeigher<? super K, ? super V> weigher) {
/**
* Creates a new {@link ConcurrentLinkedHashMap} instance.
*
* @return ConcurrentLinkedHashMap
* @throws IllegalStateException if the maximum weighted capacity was
* not set
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ private Weighers() {
* A entry weigher backed by the specified weigher. The weight of the value
* determines the weight of the entry.
*
* @param <K> K
* @param <V> V
* @param weigher the weigher to be "wrapped" in a entry weigher.
* @return A entry weigher view of the specified weigher.
*/
Expand All @@ -56,6 +58,8 @@ public static <K, V> EntryWeigher<K, V> asEntryWeigher(
* this weigher will evict when the number of key-value pairs exceeds the
* capacity.
*
* @param <K> K
* @param <V> V
* @return A weigher where a value takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand All @@ -68,6 +72,7 @@ public static <K, V> EntryWeigher<K, V> entrySingleton() {
* this weigher will evict when the number of key-value pairs exceeds the
* capacity.
*
* @param <V> V
* @return A weigher where a value takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand Down Expand Up @@ -105,7 +110,8 @@ public static Weigher<byte[]> byteArray() {
* with this weight can occur then the caller should eagerly evaluate the
* value and treat it as a removal operation. Alternatively, a custom weigher
* may be specified on the map to assign an empty value a positive weight.
*
*
* @param <E> E
* @return A weigher where each element takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand All @@ -124,6 +130,7 @@ public static <E> Weigher<? super Iterable<E>> iterable() {
* value and treat it as a removal operation. Alternatively, a custom weigher
* may be specified on the map to assign an empty value a positive weight.
*
* @param <E> E
* @return A weigher where each element takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand All @@ -142,6 +149,7 @@ public static <E> Weigher<? super Collection<E>> collection() {
* value and treat it as a removal operation. Alternatively, a custom weigher
* may be specified on the map to assign an empty value a positive weight.
*
* @param <E> E
* @return A weigher where each element takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand All @@ -160,6 +168,7 @@ public static <E> Weigher<? super List<E>> list() {
* value and treat it as a removal operation. Alternatively, a custom weigher
* may be specified on the map to assign an empty value a positive weight.
*
* @param <E> E
* @return A weigher where each element takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand All @@ -178,6 +187,8 @@ public static <E> Weigher<? super Set<E>> set() {
* value and treat it as a removal operation. Alternatively, a custom weigher
* may be specified on the map to assign an empty value a positive weight.
*
* @param <A> A
* @param <B> B
* @return A weigher where each entry takes one unit of capacity.
*/
@SuppressWarnings({"cast", "unchecked"})
Expand Down
Original file line number Diff line number Diff line change
@@ -1,41 +1,29 @@
/*
* Copyright 2011 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a
* copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations
* under the License.
*/

/**
* This package contains an implementation of a bounded
* {@link java.util.concurrent.ConcurrentMap} data structure.
* This package contains an implementation of a bounded {@link java.util.concurrent.ConcurrentMap} data structure.
* <p>
* {@link com.googlecode.concurrentlinkedhashmap.Weigher} is a simple interface
* for determining how many units of capacity an entry consumes. Depending on
* which concrete Weigher class is used, an entry may consume a different amount
* of space within the cache. The
* {@link com.googlecode.concurrentlinkedhashmap.Weighers} class provides
* utility methods for obtaining the most common kinds of implementations.
* {@link Weigher} is a simple interface for determining how many units of capacity an entry consumes. Depending on which concrete Weigher class is
* used, an entry may consume a different amount of space within the cache. The {@link Weighers} class provides utility methods for obtaining the most
* common kinds of implementations.
* <p>
* {@link com.googlecode.concurrentlinkedhashmap.EvictionListener} provides the
* ability to be notified when an entry is evicted from the map. An eviction
* occurs when the entry was automatically removed due to the map exceeding a
* capacity threshold. It is not called when an entry was explicitly removed.
* {@link EvictionListener} provides the ability to be notified when an entry is evicted from the map. An eviction occurs when the entry was
* automatically removed due to the map exceeding a capacity threshold. It is not called when an entry was explicitly removed.
* <p>
* The {@link com.googlecode.concurrentlinkedhashmap.ConcurrentLinkedHashMap}
* class supplies an efficient, scalable, thread-safe, bounded map. As with the
* <tt>Java Collections Framework</tt> the "Concurrent" prefix is used to
* indicate that the map is not governed by a single exclusion lock.
* The {@link ConcurrentLinkedHashMap} class supplies an efficient, scalable, thread-safe, bounded map. As with the
* <tt>Java Collections Framework</tt> the "Concurrent" prefix is used to indicate that the map is not governed by a single exclusion lock.
*
* @see <a href="http://code.google.com/p/concurrentlinkedhashmap/">
* http://code.google.com/p/concurrentlinkedhashmap/</a>
* @see <a href="http://code.google.com/p/concurrentlinkedhashmap/"> http://code.google.com/p/concurrentlinkedhashmap/</a>
*/
package mssql.googlecode.concurrentlinkedhashmap;

0 comments on commit ec418e0

Please sign in to comment.