id
int64
1
49k
buggy
stringlengths
34
37.5k
fixed
stringlengths
2
37k
10,601
ProductIdentifier productIdentifier = (ProductIdentifier) child; destination.setProductIdentifier(productIdentifier); } }, VERSION ("VERSION", <BUG>Arrays.asList(ParameterType.VALUE_DATA_TYPES, ParameterType.NON_STANDARD, ParameterType.IANA_PARAMETER), Version.class)</BUG> { @Override public VChild parse(VCalendar vCal...
Arrays.asList(ParameterType.VALUE_DATA_TYPES, ParameterType.NON_STANDARD), Version.class)
10,602
package jfxtras.labs.icalendarfx.components; import jfxtras.labs.icalendarfx.properties.component.descriptive.Comment; <BUG>import jfxtras.labs.icalendarfx.properties.component.misc.IANAProperty; import jfxtras.labs.icalendarfx.properties.component.misc.UnknownProperty;</BUG> import jfxtras.labs.icalendarfx.properties...
import jfxtras.labs.icalendarfx.properties.component.misc.NonStandardProperty;
10,603
minX = src.getMinX(); maxX = src.getMaxX(); minY = src.getMinY(); maxY = src.getMaxY(); } else { <BUG>iterSource = RandomIterFactory.create(src, src.getBounds(), TILE_CACHED, ARRAY_CALC); minX = src.getMinX() + 1; // Left padding maxX = src.getMaxX() - 2; // Right padding minY = src.getMinY() + 1; // Top padding max...
iterSource = getRandomIterator(src, null); minX = src.getMinX() + leftPad; // Left padding maxX = src.getMaxX() - rightPad; // Right padding minY = src.getMinY() + topPad; // Top padding maxY = src.getMaxY() - bottomPad; // Bottom padding
10,604
final int lineStride = dst.getScanlineStride(); final int pixelStride = dst.getPixelStride(); final int[] bandOffsets = dst.getBandOffsets(); final byte[][] data = dst.getByteDataArrays(); final float[] warpData = new float[2 * dstWidth]; <BUG>int lineOffset = 0; if (ctable == null) { // source does not have IndexColor...
if(hasROI && !roiContainsTile && roiIter == null){ throw new IllegalArgumentException("Error on creating the ROI iterator"); } if (caseA || (caseB && roiContainsTile)) { for (int h = 0; h < dstHeight; h++) {
10,605
pixelOffset += pixelStride; } // COLS LOOP } // ROWS LOOP } } else {// source has IndexColorModel <BUG>if (caseA) { for (int h = 0; h < dstHeight; h++) {</BUG> int pixelOffset = lineOffset; lineOffset += lineStride; warp.warpRect(dst.getX(), dst.getY() + h, dstWidth, 1, warpData);
} else if (caseB) { for (int h = 0; h < dstHeight; h++) {
10,606
minX = src.getMinX(); maxX = src.getMaxX(); minY = src.getMinY(); maxY = src.getMaxY(); } else { <BUG>iterSource = RandomIterFactory.create(src, src.getBounds(), TILE_CACHED, ARRAY_CALC); minX = src.getMinX() + 1; // Left padding maxX = src.getMaxX() - 2; // Right padding minY = src.getMinY() + 1; // Top padding max...
iterSource = getRandomIterator(src, null); minX = src.getMinX() + leftPad; // Left padding maxX = src.getMaxX() - rightPad; // Right padding minY = src.getMinY() + topPad; // Top padding maxY = src.getMaxY() - bottomPad; // Bottom padding
10,607
final int pixelStride = dst.getPixelStride(); final int[] bandOffsets = dst.getBandOffsets(); final short[][] data = dst.getShortDataArrays(); final float[] warpData = new float[2 * dstWidth]; int lineOffset = 0; <BUG>if (caseA) { for (int h = 0; h < dstHeight; h++) {</BUG> int pixelOffset = lineOffset; lineOffset += l...
if(hasROI && !roiContainsTile && roiIter == null){ throw new IllegalArgumentException("Error on creating the ROI iterator"); } if (caseA || (caseB && roiContainsTile)) { for (int h = 0; h < dstHeight; h++) {
10,608
minX = src.getMinX(); maxX = src.getMaxX(); minY = src.getMinY(); maxY = src.getMaxY(); } else { <BUG>iterSource = RandomIterFactory.create(src, src.getBounds(), TILE_CACHED, ARRAY_CALC); minX = src.getMinX() + 1; // Left padding maxX = src.getMaxX() - 2; // Right padding minY = src.getMinY() + 1; // Top padding max...
iterSource = getRandomIterator(src, null); minX = src.getMinX() + leftPad; // Left padding maxX = src.getMaxX() - rightPad; // Right padding minY = src.getMinY() + topPad; // Top padding maxY = src.getMaxY() - bottomPad; // Bottom padding
10,609
final int pixelStride = dst.getPixelStride(); final int[] bandOffsets = dst.getBandOffsets(); final short[][] data = dst.getShortDataArrays(); final float[] warpData = new float[2 * dstWidth]; int lineOffset = 0; <BUG>if (caseA) { for (int h = 0; h < dstHeight; h++) {</BUG> int pixelOffset = lineOffset; lineOffset += l...
if(hasROI && !roiContainsTile && roiIter == null){ throw new IllegalArgumentException("Error on creating the ROI iterator"); } if (caseA || (caseB && roiContainsTile)) { for (int h = 0; h < dstHeight; h++) {
10,610
minX = src.getMinX(); maxX = src.getMaxX(); minY = src.getMinY(); maxY = src.getMaxY(); } else { <BUG>iterSource = RandomIterFactory.create(src, src.getBounds(), TILE_CACHED, ARRAY_CALC); minX = src.getMinX() + 1; // Left padding maxX = src.getMaxX() - 2; // Right padding minY = src.getMinY() + 1; // Top padding max...
iterSource = getRandomIterator(src, null); minX = src.getMinX() + leftPad; // Left padding maxX = src.getMaxX() - rightPad; // Right padding minY = src.getMinY() + topPad; // Top padding maxY = src.getMaxY() - bottomPad; // Bottom padding
10,611
final int pixelStride = dst.getPixelStride(); final int[] bandOffsets = dst.getBandOffsets(); final int[][] data = dst.getIntDataArrays(); final float[] warpData = new float[2 * dstWidth]; int lineOffset = 0; <BUG>if (caseA) { for (int h = 0; h < dstHeight; h++) {</BUG> int pixelOffset = lineOffset; lineOffset += lineS...
if(hasROI && !roiContainsTile && roiIter == null){ throw new IllegalArgumentException("Error on creating the ROI iterator"); } if (caseA || (caseB && roiContainsTile)) { for (int h = 0; h < dstHeight; h++) {
10,612
minX = src.getMinX(); maxX = src.getMaxX(); minY = src.getMinY(); maxY = src.getMaxY(); } else { <BUG>iterSource = RandomIterFactory.create(src, src.getBounds(), TILE_CACHED, ARRAY_CALC); minX = src.getMinX() + 1; // Left padding maxX = src.getMaxX() - 2; // Right padding minY = src.getMinY() + 1; // Top padding max...
iterSource = getRandomIterator(src, null); minX = src.getMinX() + leftPad; // Left padding maxX = src.getMaxX() - rightPad; // Right padding minY = src.getMinY() + topPad; // Top padding maxY = src.getMaxY() - bottomPad; // Bottom padding
10,613
final int pixelStride = dst.getPixelStride(); final int[] bandOffsets = dst.getBandOffsets(); final float[][] data = dst.getFloatDataArrays(); final float[] warpData = new float[2 * dstWidth]; int lineOffset = 0; <BUG>if (caseA) { for (int h = 0; h < dstHeight; h++) {</BUG> int pixelOffset = lineOffset; lineOffset += l...
if(hasROI && !roiContainsTile && roiIter == null){ throw new IllegalArgumentException("Error on creating the ROI iterator"); } if (caseA || (caseB && roiContainsTile)) { for (int h = 0; h < dstHeight; h++) {
10,614
minX = src.getMinX(); maxX = src.getMaxX(); minY = src.getMinY(); maxY = src.getMaxY(); } else { <BUG>iterSource = RandomIterFactory.create(src, src.getBounds(), TILE_CACHED, ARRAY_CALC); minX = src.getMinX() + 1; // Left padding maxX = src.getMaxX() - 2; // Right padding minY = src.getMinY() + 1; // Top padding max...
iterSource = getRandomIterator(src, null); minX = src.getMinX() + leftPad; // Left padding maxX = src.getMaxX() - rightPad; // Right padding minY = src.getMinY() + topPad; // Top padding maxY = src.getMaxY() - bottomPad; // Bottom padding
10,615
final int pixelStride = dst.getPixelStride(); final int[] bandOffsets = dst.getBandOffsets(); final double[][] data = dst.getDoubleDataArrays(); final float[] warpData = new float[2 * dstWidth]; int lineOffset = 0; <BUG>if (caseA) { for (int h = 0; h < dstHeight; h++) {</BUG> int pixelOffset = lineOffset; lineOffset +=...
if(hasROI && !roiContainsTile && roiIter == null){ throw new IllegalArgumentException("Error on creating the ROI iterator"); } if (caseA || (caseB && roiContainsTile)) { for (int h = 0; h < dstHeight; h++) {
10,616
return new CollectionSet(agent, this); } public Collection<AttributeType> getAttributeTypes(CollectionAgent agent, int ifType) { String sysObjectId = agent.getSysObjectId(); String hostAddress = agent.getHostAddress(); <BUG>List<MibObject> oidList = DataCollectionConfigFactory.getInstance().getMibObjectList(getName(), ...
List<MibObject> oidList = getDataCollectionConfig().getMibObjectList(getName(), sysObjectId, hostAddress, ifType); Map<String, AttributeGroupType> groupTypes = new HashMap<String, AttributeGroupType>(); List<AttributeType> typeList = new LinkedList<AttributeType>();
10,617
typeList.add(attrType); } log().debug("getAttributeTypes(" + agent + ", " + ifType + "): " + typeList); return typeList; } <BUG>private AttributeGroupType getGroup(Map groupTypes, MibObject mibObject) { AttributeGroupType groupType = (AttributeGroupType) groupTypes.get(mibObject.getGroupName()); if (groupType == null)...
private AttributeGroupType getGroup(Map<String, AttributeGroupType> groupTypes, MibObject mibObject) { AttributeGroupType groupType = groupTypes.get(mibObject.getGroupName()); if (groupType == null) {
10,618
return m_ifAliasResourceType; } private Map<String, ResourceType> getGenericIndexResourceTypes(CollectionAgent agent) { if (m_genericIndexResourceTypes == null) { Collection<org.opennms.netmgt.config.datacollection.ResourceType> configuredResourceTypes = <BUG>DataCollectionConfigFactory.getInstance().getConfiguredResou...
getDataCollectionConfig().getConfiguredResourceTypes().values();
10,619
return m_genericIndexResourceTypes; } private ResourceType getGenericIndexResourceType(CollectionAgent agent, String name) { return getGenericIndexResourceTypes(agent).get(name); } <BUG>private Collection getResourceTypes(CollectionAgent agent) { HashSet set = new HashSet(3); set.add(getNodeResourceType(agent));</BUG>...
private Collection<ResourceType> getResourceTypes(CollectionAgent agent) { HashSet<ResourceType> set = new HashSet<ResourceType>(3); set.add(getNodeResourceType(agent));
10,620
set.add(getIfResourceType(agent)); set.add(getIfAliasResourceType(agent)); set.addAll(getGenericIndexResourceTypes(agent).values()); return set; } <BUG>public Collection getAttributeTypes(CollectionAgent agent) { HashSet set = new HashSet(); for (Iterator it = getResourceTypes(agent).iterator(); it.hasNext();) { Resou...
public Collection<AttributeType> getAttributeTypes(CollectionAgent agent) { HashSet<AttributeType> set = new HashSet<AttributeType>(); for (ResourceType resourceType : getResourceTypes(agent)) {
10,621
if (!(sender instanceof Player)) { sender.sendMessage(plugin.getCore().getMessage("no-console")); return true; } if (plugin.isBungeeCord()) { <BUG>plugin.sendBungeeActivateMessage(sender, sender.getName(), false); String message = plugin.getCore().getMessage("wait-on-proxy"); if (message != null) { sender.sendMessage(m...
plugin.getCore().sendLocaleMessage("wait-on-proxy", sender);
10,622
profile.setUuid(null); Bukkit.getScheduler().runTaskAsynchronously(plugin, () -> { plugin.getCore().getStorage().save(profile); }); } else { <BUG>sender.sendMessage(plugin.getCore().getMessage("not-premium")); }</BUG> } return true; } else {
plugin.getCore().sendLocaleMessage("not-premium", sender);
10,623
if (profile == null) { sender.sendMessage("Error occured"); return; } if (profile.getUserId() != -1 && !profile.isPremium()) { <BUG>sender.sendMessage(plugin.getCore().getMessage("not-premium-other")); } else { sender.sendMessage(plugin.getCore().getMessage("remove-premium")); profile.setPremium(false);</BUG> Bukkit.ge...
plugin.getCore().sendLocaleMessage("not-premium-other", sender); plugin.getCore().sendLocaleMessage("remove-premium", sender); profile.setPremium(false);
10,624
import com.github.games647.fastlogin.bukkit.BukkitLoginSession; import com.github.games647.fastlogin.bukkit.FastLoginBukkit; import com.github.games647.fastlogin.core.PlayerProfile; import com.github.games647.fastlogin.core.shared.JoinManagement; import java.util.Random; <BUG>import java.util.logging.Level; import org....
import org.bukkit.command.CommandSender; public class NameCheckTask extends JoinManagement<Player, CommandSender, ProtocolLibLoginSource> private final FastLoginBukkit plugin;
10,625
BukkitLoginSession session = plugin.getSessions().get(fromPlayer.getAddress().toString()); if (session == null) { disconnect(plugin.getCore().getMessage("invalid-requst"), true , "Player {0} tried to send encryption response at invalid state", fromPlayer.getAddress()); } else { <BUG>String ip = fromPlayer.getAddress()....
[DELETED]
10,626
if (core != null) { core.close(); } getServer().getOnlinePlayers().forEach(player -> player.removeMetadata(getName(), this)); } <BUG>public BukkitCore getCore() { return core;</BUG> } public void sendBungeeActivateMessage(CommandSender sender, String target, boolean activate) { if (sender instanceof Player) {
public FastLoginCore<Player, CommandSender, FastLoginBukkit> getCore() { return core;
10,627
String id = '/' + address.getAddress().getHostAddress() + ':' + address.getPort(); if ("AUTO_LOGIN".equalsIgnoreCase(subchannel)) { BukkitLoginSession playerSession = new BukkitLoginSession(playerName, true); playerSession.setVerified(true); plugin.getSessions().put(id, playerSession); <BUG>Bukkit.getScheduler().runTas...
Bukkit.getScheduler().runTaskAsynchronously(plugin, new ForceLoginTask(plugin.getCore(), player));
10,628
try { if (authPlugin == null || !authPlugin.isRegistered(playerName)) { BukkitLoginSession playerSession = new BukkitLoginSession(playerName, false); playerSession.setVerified(true); plugin.getSessions().put(id, playerSession); <BUG>new ForceLoginTask(plugin, player).run(); </BUG> } } catch (Exception ex) { plugin.getL...
new ForceLoginTask(plugin.getCore(), player).run();
10,629
package com.autonomy.abc.selenium.find.numericWidgets; import com.hp.autonomy.frontend.selenium.util.AppElement; import org.openqa.selenium.By; import org.openqa.selenium.WebDriver; <BUG>import org.openqa.selenium.WebElement; import java.util.ArrayList;</BUG> import java.util.List; public class NumericWidget extends Ap...
import org.openqa.selenium.support.ui.ExpectedConditions; import org.openqa.selenium.support.ui.WebDriverWait; import java.util.ArrayList;
10,630
Integer datasetId; String datasetUrn; String capacityName; String capacityType; String capacityUnit; <BUG>String capacityLow; String capacityHigh; </BUG> Long modifiedTime;
Long capacityLow; Long capacityHigh;
10,631
import com.fasterxml.jackson.databind.ObjectMapper; public class DatasetFieldPathRecord { String fieldPath; String role; public DatasetFieldPathRecord() { <BUG>} @Override public String toString() { try { return new ObjectMapper().writeValueAsString(this); } catch (JsonProcessingException ex) { return null; }</BUG> }
[DELETED]
10,632
new DatabaseWriter(JdbcUtil.wherehowsJdbcTemplate, DATASET_INVENTORY_TABLE); public static final String GET_DATASET_DEPLOYMENT_BY_DATASET_ID = "SELECT * FROM " + DATASET_DEPLOYMENT_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_DEPLOYMENT_BY_URN = "SELECT * FROM " + DATASET_DEPLOYMENT...
public static final String DELETE_DATASET_DEPLOYMENT_BY_DATASET_ID = "DELETE FROM " + DATASET_DEPLOYMENT_TABLE + " WHERE dataset_id=?";
10,633
</BUG> public static final String GET_DATASET_CAPACITY_BY_DATASET_ID = "SELECT * FROM " + DATASET_CAPACITY_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_CAPACITY_BY_URN = "SELECT * FROM " + DATASET_CAPACITY_TABLE + " WHERE dataset_urn = :dataset_urn"; <BUG>public static final String ...
new DatabaseWriter(JdbcUtil.wherehowsJdbcTemplate, DATASET_INVENTORY_TABLE); public static final String GET_DATASET_DEPLOYMENT_BY_DATASET_ID = "SELECT * FROM " + DATASET_DEPLOYMENT_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_DEPLOYMENT_BY_URN = "SELECT * FROM " + DATASET_DEPLOYMENT...
10,634
"SELECT * FROM " + DATASET_CASE_SENSITIVE_TABLE + " WHERE dataset_urn = :dataset_urn"; public static final String GET_DATASET_REFERENCE_BY_DATASET_ID = "SELECT * FROM " + DATASET_REFERENCE_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_REFERENCE_BY_URN = "SELECT * FROM " + DATASET_REF...
public static final String DELETE_DATASET_REFERENCE_BY_DATASET_ID = "DELETE FROM " + DATASET_REFERENCE_TABLE + " WHERE dataset_id=?";
10,635
"SELECT * FROM " + DATASET_SECURITY_TABLE + " WHERE dataset_urn = :dataset_urn"; public static final String GET_DATASET_OWNER_BY_DATASET_ID = "SELECT * FROM " + DATASET_OWNER_TABLE + " WHERE dataset_id = :dataset_id ORDER BY sort_id"; public static final String GET_DATASET_OWNER_BY_URN = "SELECT * FROM " + DATASET_OWNE...
public static final String DELETE_DATASET_OWNER_BY_DATASET_ID = "DELETE FROM " + DATASET_OWNER_TABLE + " WHERE dataset_id=?";
10,636
"SELECT app_id FROM " + EXTERNAL_GROUP_TABLE + " WHERE group_id = :group_id GROUP BY group_id"; public static final String GET_DATASET_CONSTRAINT_BY_DATASET_ID = "SELECT * FROM " + DATASET_CONSTRAINT_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_CONSTRAINT_BY_URN = "SELECT * FROM " +...
public static final String DELETE_DATASET_CONSTRAINT_BY_DATASET_ID = "DELETE FROM " + DATASET_CONSTRAINT_TABLE + " WHERE dataset_id=?";
10,637
</BUG> public static final String GET_DATASET_INDEX_BY_DATASET_ID = "SELECT * FROM " + DATASET_INDEX_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_INDEX_BY_URN = "SELECT * FROM " + DATASET_INDEX_TABLE + " WHERE dataset_urn = :dataset_urn"; <BUG>public static final String DELETE_DATAS...
"SELECT app_id FROM " + EXTERNAL_GROUP_TABLE + " WHERE group_id = :group_id GROUP BY group_id"; public static final String GET_DATASET_CONSTRAINT_BY_DATASET_ID = "SELECT * FROM " + DATASET_CONSTRAINT_TABLE + " WHERE dataset_id = :dataset_id"; public static final String GET_DATASET_CONSTRAINT_BY_URN = "SELECT * FROM " +...
10,638
DatasetSecurityRecord record = om.convertValue(security, DatasetSecurityRecord.class); record.setDatasetId(datasetId); record.setDatasetUrn(urn); record.setModifiedTime(System.currentTimeMillis() / 1000); try { <BUG>Map<String, Object> result = getDatasetSecurityByDatasetId(datasetId); </BUG> String[] columns = record....
DatasetSecurityRecord result = getDatasetSecurityByDatasetId(datasetId);
10,639
"confidential_flags", "is_recursive", "partitioned", "indexed", "namespace", "default_comment_id", "comment_ids"}; } @Override public List<Object> fillAllFields() { return null; <BUG>} public String[] getFieldDetailColumns() {</BUG> return new String[]{"dataset_id", "sort_id", "parent_sort_id", "parent_path", "field_na...
@JsonIgnore public String[] getFieldDetailColumns() {
10,640
partitioned != null && partitioned ? "Y" : "N", isRecursive != null && isRecursive ? "Y" : "N", confidentialFlags, defaultValue, namespace, defaultCommentId, commentIds}; } public DatasetFieldSchemaRecord() { } <BUG>@Override public String toString() { try { return new ObjectMapper().writeValueAsString(this.getFieldVal...
[DELETED]
10,641
String fieldPath; String descend; Integer prefixLength; String filter; public DatasetFieldIndexRecord() { <BUG>} @Override public String toString() { try { return new ObjectMapper().writeValueAsString(this); } catch (JsonProcessingException ex) { return null; }</BUG> }
[DELETED]
10,642
String actorUrn; String type; Long time; String note; public DatasetChangeAuditStamp() { <BUG>} @Override public String toString() { try { return new ObjectMapper().writeValueAsString(this); } catch (JsonProcessingException ex) { return null; }</BUG> }
[DELETED]
10,643
package wherehows.common.schemas; <BUG>import com.fasterxml.jackson.annotation.JsonIgnore; import java.lang.reflect.Field; import java.util.HashMap;</BUG> import java.util.List; import java.util.Map;
import com.fasterxml.jackson.databind.ObjectMapper; import java.io.IOException; import java.util.Date; import java.util.Collection; import java.util.HashMap;
10,644
TiffWriter tw = new TiffWriter(ti); tw.SetModel(td); tw.write(pathFixed); ti.close(); tr = new TiffReader(); <BUG>tr.readFile(pathFixed); </BUG> TiffDocument to = tr.getModel(); Map<String, Validator> validationsFixed = getValidations(tr, config); pathNorm = pathFixed.replaceAll("\\\\", "/");
tr.readFile(pathFixed, false);
10,645
if (tag.dif < 0) sDif = "<i class=\"fa fa-times\"></i>"; else if (tag.dif > 0) sDif = "<i class=\"fa fa-plus\"></i>"; row = row.replace("##ICON##", "<i class=\"image-default icon-" + tag.tv.getName().toLowerCase() + "\"></i>"); row = row.replace("##ID##", tag.tv.getId() + sDif); row = row.replace("##KEY##", (tag.tv.get...
String val = tag.tv.getDescriptiveValue(); if (val.length() > 200) val = val.substring(0, 200) + "..."; row = row.replace("##VALUE##", val); String rows = tagsMap.containsKey(mapId) ? tagsMap.get(mapId) : "";
10,646
if (!op2.valid) { ok = false; } else { String value2 = op2.getValue(); if (value2 == null) <BUG>op2.getValue(); if (value.contains("/"))</BUG> value = Double.parseDouble(value.split("/")[0]) / Double.parseDouble(value.split("/")[1]) + ""; if (value2.contains("/")) value2 = Double.parseDouble(value2.split("/")[0]) / Dou...
value2 = ""; if (value.contains("/"))
10,647
ycbcr.setYCbCrPositioning(yCbCrPositioning); photometricInterpretation.setYCbCr(ycbcr); if (ifd.getMetadata() != null && ifd.getMetadata().containsTagId(TiffTags.getTagId("ReferenceBlackWhite"))) { BasicImageInformationType.BasicImageCharacteristics.PhotometricInterpretation.ReferenceBlackWhite referenceBlackWhite = ne...
if (ifd.getMetadata().get("ReferenceBlackWhite").getValue().get(0) instanceof Rational && ifd.getMetadata().get("ReferenceBlackWhite").getValue().size() > 0 && ifd.getMetadata().get("ReferenceBlackWhite").getValue().get(1) instanceof Rational) {
10,648
if (planar == 2) { long spp_tpi = spp * tilesPerImage; if (ifd.getImageTiles().getTiles().size() < spp_tpi) { tiffIfd.setCorrectTiles(0); } <BUG>} }</BUG> } if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("BitsPerSample")) && metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("Sam...
} else {
10,649
if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("Compression")) && metadata.get("Compression").getFirstNumericValue() == 1) { if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("CompressedBitsPerPixel"))) { correctCompression = false; } } <BUG>if (metadata.containsTagId(com.ea...
if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("PhotometricInterpretation")) && metadata.get("PhotometricInterpretation").getCardinality() > 0) {
10,650
if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("YCbCrSubSampling"))) correctPhotometricCasuistic = false; if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("YCbCrPositioning"))) correctPhotometricCasuistic = false; if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTag...
if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("SamplesPerPixel")) && metadata.get("SamplesPerPixel").getCardinality() > 0)
10,651
if (photo == 32803) { if (!metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("CFARepeatPatternDim"))) correctPhotometricCasuistic = false; else if (metadata.get("CFARepeatPatternDim").getCardinality() != 2) correctPhotometricCasuistic = false; if (!metadata.containsTagId(com.easyinnova.tiff.model.TiffT...
} else {
10,652
TagValue tv = metadata.get(com.easyinnova.tiff.model.TiffTags.getTagId("BitsPerSample")); if (tv.getCardinality()>0) { bps = (int) tv.getFirstNumericValue(); } } <BUG>if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("PlanarConfiguration"))) { planar = (int)metadata.get(com.easyinnova.tiff.model.Ti...
if (metadata.containsTagId(com.easyinnova.tiff.model.TiffTags.getTagId("PlanarConfiguration")) && metadata.get(com.easyinnova.tiff.model.TiffTags.getTagId("PlanarConfiguration")).getCardinality() > 0) { planar = (int)metadata.get(com.easyinnova.tiff.model.TiffTags.getTagId("PlanarConfiguration")).getFirstNumericValue()...
10,653
List<TiffTag> tags = new ArrayList<TiffTag>(); int prevTagId = -1; boolean correctTagOrdering = true; boolean duplicatedTags = false; HashSet tagIds = new HashSet<>(); <BUG>IFD exif = (IFD) tv.getValue().get(0); for (TagValue tvv : exif.getTags().getTags()) {</BUG> if (tvv.getId() <= prevTagId) { correctTagOrdering = f...
abstractTiffType obj = tv.getValue().get(0); if (obj instanceof IFD) { IFD exif = (IFD) obj; for (TagValue tvv : exif.getTags().getTags()) {
10,654
tiffTags.setTags(tags); ifd.setTags(tiffTags); ifd.setTagOrdering(correctTagOrdering ? 1 : 0); ifd.setDuplicateTags(duplicatedTags ? 1 : 0); ifd.setClassElement(nodeName); <BUG>return ifd; }</BUG> boolean checkOffsetOverlapped(int offset, int length) { for (Integer usedOffset : usedOffsetsSizes.keySet()) { int size = u...
} else { return null; } }
10,655
builder.startStatement().string("s[1] = (byte)0b00 /* inactive */").end(); builder.end(); builder.startStatement().string("data[", String.valueOf(index), "] = s").end(); index++; } <BUG>builder.startReturn().string("data").end(); clazz.add(reflection);</BUG> } private void createFields(CodeTypeElement clazz) { CodeVari...
builder.startReturn().startNew(context.getType(Introspection.Data.class)).string("data").end().end(); clazz.add(reflection);
10,656
@Override public void preInit() { asphalt = MilitaryBaseDecor.INSTANCE.getManager().newBlock(BlockAsphalt.class, ItemBlockColdWar.class); reinforcedRail = MilitaryBaseDecor.INSTANCE.getManager().newBlock(BlockReinforcedRail.class, ItemBlockColdWar.class); <BUG>MilitaryBaseDecor.CREATIVE_TAB_1.itemStack = new ItemStack(...
MilitaryBaseDecor.MAIN_TAB.itemStack = new ItemStack(asphalt);
10,657
this.setBlockName("reinforced_rail"); this.setBlockTextureName(MilitaryBaseDecor.PREFIX + "reinforced_rail"); this.setHardness(10F); this.setResistance(10F); this.setStepSound(soundTypeMetal); <BUG>this.setCreativeTab(MilitaryBaseDecor.CREATIVE_TAB_1); </BUG> } @Override public float getRailMaxSpeed(World world, Entity...
this.setCreativeTab(MilitaryBaseDecor.MAIN_TAB);
10,658
public static final String ASSETS_PATH = "/assets/militarybasedecor/"; public static final String TEXTURE_PATH = "textures/"; public static final String GUI_PATH = TEXTURE_PATH + "gui/";</BUG> public static final String MODEL_PATH = "models/"; <BUG>public static final String MODEL_DIRECTORY = ASSETS_PATH + MODEL_PATH; ...
import cpw.mods.fml.common.event.FMLPreInitializationEvent; @Mod(modid = MilitaryBaseDecor.DOMAIN, name = "Military Base Decor", version = "@MAJOR@.@MINOR@.@REVIS@.@BUILD@", dependencies = "required-after:VoltzEngine") public final class MilitaryBaseDecor extends AbstractMod { public static final String DOMAIN = "milit...
10,659
public static final IModelCustom GLASS_FLOOR_PANEL_MODEL = model("Glass_Floor_Panel.tcn"); public static final IModelCustom REINFORCED_GLASS_FLOOR_PANEL_MODEL = model("Reinforced_Glass_Floor_Panel.tcn");</BUG> public static final IModelCustom ADVANCED_SANDBAG_MODEL = model("Advanced_Sandbag.tcn"); public static final R...
import net.minecraftforge.client.model.IModelCustom; @SideOnly(Side.CLIENT) public final class Assets public static final IModelCustom PANE_BARBS_MODEL = model("Pane_Barbs.tcn");
10,660
public void onClickStop(View v) { if (mMediaPlayer != null) { mMediaPlayer.stop(); mMediaPlayer.reset(); } <BUG>mIsStopped = true; }</BUG> public void releaseWithoutStop() { if (mMediaPlayer != null) { mMediaPlayer.setDisplay(null);
mMediaPlayer = null;
10,661
package com.pili.pldroid.playerdemo; import android.app.Activity; <BUG>import android.app.AlertDialog; import android.content.Context; import android.content.DialogInterface;</BUG> import android.content.Intent; import android.os.Bundle;
[DELETED]
10,662
mEditText.setText(DEFAULT_TEST_URL); mActivitySpinner = (Spinner) findViewById(R.id.TestSpinner);</BUG> ArrayAdapter<String> adapter = new ArrayAdapter<String>(this, android.R.layout.simple_list_item_1, TEST_ACTIVITY_ARRAY); mActivitySpinner.setAdapter(adapter); } <BUG>public void onClickPlaySetting(View v) { showPlayS...
mStreamingTypeRadioGroup = (RadioGroup) findViewById(R.id.StreamingTypeRadioGroup); mDecodeTypeRadioGroup = (RadioGroup) findViewById(R.id.DecodeTypeRadioGroup); mActivitySpinner = (Spinner) findViewById(R.id.TestSpinner); @Override protected void onDestroy() { super.onDestroy(); PLNetworkManager.getInstance().stopDnsC...
10,663
mVideoView.setOnBufferingUpdateListener(mOnBufferingUpdateListener); mVideoView.setOnCompletionListener(mOnCompletionListener); mVideoView.setOnSeekCompleteListener(mOnSeekCompleteListener); mVideoView.setOnErrorListener(mOnErrorListener); mVideoView.setVideoPath(mVideoPath); <BUG>mMediaController = new MediaController...
mMediaController = new MediaController(this, false, isLiveStreaming==1);
10,664
correctPixel = true; do_corr[iy - y][ix - x] = true; } else { do_corr[iy - y][ix - x] = false; for (int bandId = 0; bandId < L1_BAND_NUM; bandId++) { <BUG>if (bandId == bb11 || bandId == bb15) { continue; }</BUG> brr[bandId].setSample(ix, iy, BAD_VALUE);
if (bandId != bb11 && bandId != bb15) {
10,665
press = press * pressureCorrectionCloud; } } rayleighCorrection.phase_rayleigh(mus, muv, sins, sinv, phaseR); rayleighCorrection.tau_rayleigh(press, tauR); <BUG>rayleighCorrection.ref_rayleigh(deltaAzimuth, sza.getSampleFloat(x, y), vza.getSampleFloat(x, y), mus, muv, airMass, phaseR, tauR, rhoR);</BUG> rayleighCorrect...
rayleighCorrection.ref_rayleigh(deltaAzimuth, szaSampleFloat, vzaSampleFloat, mus, muv, airMass, phaseR, tauR, rhoR);
10,666
package org.esa.beam.meris.cloud; <BUG>import java.awt.Rectangle; import org.esa.beam.framework.datamodel.Band;</BUG> import org.esa.beam.framework.datamodel.FlagCoding; import org.esa.beam.framework.datamodel.Product; import org.esa.beam.framework.gpf.OperatorException;
import com.bc.ceres.core.ProgressMonitor; import org.esa.beam.framework.datamodel.Band;
10,667
import org.esa.beam.framework.gpf.annotations.SourceProduct; import org.esa.beam.framework.gpf.annotations.TargetProduct; import org.esa.beam.gpf.operators.meris.MerisBasisOp; import org.esa.beam.util.ProductUtils; import org.esa.beam.util.RectangleExtender; <BUG>import com.bc.ceres.core.ProgressMonitor; public class C...
import java.awt.Rectangle; public class CloudEdgeOp extends MerisBasisOp {
10,668
a_thresh = auxData.alpha_thresh[1]; rThresh = r13thresh_val; } boolean is_ice = false; if (rhoToaProduct != null) { <BUG>final double mdsi = (rhoToa[12].getSampleDouble(x,y) - rhoToa[13].getSampleDouble(x,y))/ (rhoToa[12].getSampleDouble(x,y) + rhoToa[13].getSampleDouble(x,y)); is_ice = (mdsi > 0.01 && l1Flags.getSampl...
final double mdsi = (rhoToa12.getSampleDouble(x,y) - rhoToa13.getSampleDouble(x,y))/ (rhoToa12.getSampleDouble(x,y) + rhoToa13.getSampleDouble(x,y)); is_ice = (mdsi > 0.01 && l1Flags.getSampleBit(ix, iy, L1_F_BRIGHT));
10,669
package org.esa.beam.meris.cloud; <BUG>import java.awt.Rectangle; import org.esa.beam.dataio.envisat.EnvisatConstants;</BUG> import org.esa.beam.framework.datamodel.Band; import org.esa.beam.framework.datamodel.FlagCoding; import org.esa.beam.framework.datamodel.GeoCoding;
import com.bc.ceres.core.ProgressMonitor; import org.esa.beam.dataio.envisat.EnvisatConstants;
10,670
import org.esa.beam.framework.gpf.annotations.TargetProduct; import org.esa.beam.gpf.operators.meris.MerisBasisOp; import org.esa.beam.util.ProductUtils; import org.esa.beam.util.RectangleExtender; import org.esa.beam.util.math.MathUtils; <BUG>import com.bc.ceres.core.ProgressMonitor; public class CloudShadowOp extends...
import java.awt.Rectangle; public class CloudShadowOp extends MerisBasisOp {
10,671
public void computeTile(Band band, Tile targetTile, ProgressMonitor pm) throws OperatorException { Rectangle rectangle = targetTile.getRectangle(); pm.beginTask("Processing frame...", rectangle.height); try { Tile detector = getSourceTile(sourceProduct.getBand(EnvisatConstants.MERIS_DETECTOR_INDEX_DS_NAME), rectangle, ...
Tile sza = null; Tile saa = null; Tile vza = null; Tile vaa = null; Tile lat = null; Tile lon = null; Tile toar10 = getSourceTile(sourceProduct.getBand("radiance_10"), rectangle, pm);
10,672
Tile toar11 = getSourceTile(sourceProduct.getBand("radiance_11"), rectangle, pm); Tile isInvalid = getSourceTile(invalidBand, rectangle, pm); Tile l1bFlags = getSourceTile(sourceProduct.getBand(EnvisatConstants.MERIS_L1B_FLAGS_DS_NAME), rectangle, pm); final double[] nnInWater = new double[6]; final double[] nnInLand =...
JnnNet nnLand = null; JnnNet nnWater = null;
10,673
nnInLand[3] = Math.cos(szaRad); nnInLand[4] = Math.cos(vzaRad); nnInLand[5] = Math.sin(vzaRad) nnInLand[6] = lambda; nnLand.process(nnInLand, nnOut); <BUG>} else { nnInWater[0] = toar10.getSampleDouble(x, y); nnInWater[1] = toar11XY_corrected / toar10.getSampleDouble(x, y);</BUG> nnInWater[2] = Math.cos(szaRad);
if(nnWater == null) { nnWater = neuralNetWater.clone(); } nnInWater[1] = toar11XY_corrected / toar10.getSampleDouble(x, y);
10,674
} @RootTask static Task<Exec.Result> exec(String parameter, int number) { Task<String> task1 = MyTask.create(parameter); Task<Integer> task2 = Adder.create(number, number + 2); <BUG>return Task.ofType(Exec.Result.class).named("exec", "/bin/sh") .in(() -> task1)</BUG> .in(() -> task2) .process(Exec.exec((str, i) -> args...
return Task.named("exec", "/bin/sh").ofType(Exec.Result.class) .in(() -> task1)
10,675
return args; } static class MyTask { static final int PLUS = 10; static Task<String> create(String parameter) { <BUG>return Task.ofType(String.class).named("MyTask", parameter) .in(() -> Adder.create(parameter.length(), PLUS))</BUG> .in(() -> Fib.create(parameter.length())) .process((sum, fib) -> something(parameter, s...
return Task.named("MyTask", parameter).ofType(String.class) .in(() -> Adder.create(parameter.length(), PLUS))
10,676
final String instanceField = "from instance"; final TaskContext context = TaskContext.inmem(); final AwaitingConsumer<String> val = new AwaitingConsumer<>(); @Test public void shouldJavaUtilSerialize() throws Exception { <BUG>Task<Long> task1 = Task.ofType(Long.class).named("Foo", "Bar", 39) .process(() -> 9999L); Task...
Task<Long> task1 = Task.named("Foo", "Bar", 39).ofType(Long.class) Task<String> task2 = Task.named("Baz", 40).ofType(String.class) .in(() -> task1)
10,677
assertEquals(des.id().name(), "Baz"); assertEquals(val.awaitAndGet(), "[9999] hello 10004"); } @Test(expected = NotSerializableException.class) public void shouldNotSerializeWithInstanceFieldReference() throws Exception { <BUG>Task<String> task = Task.ofType(String.class).named("WithRef") .process(() -> instanceField +...
Task<String> task = Task.named("WithRef").ofType(String.class) .process(() -> instanceField + " causes an outer reference");
10,678
serialize(task); } @Test public void shouldSerializeWithLocalReference() throws Exception { String local = instanceField; <BUG>Task<String> task = Task.ofType(String.class).named("WithLocalRef") .process(() -> local + " won't cause an outer reference");</BUG> serialize(task); Task<String> des = deserialize(); context.e...
Task<String> task = Task.named("WithLocalRef").ofType(String.class) .process(() -> local + " won't cause an outer reference");
10,679
} @RootTask public static Task<String> standardArgs(int first, String second) { firstInt = first; secondString = second; <BUG>return Task.ofType(String.class).named("StandardArgs", first, second) .process(() -> second + " " + first * 100);</BUG> } @Test public void shouldParseFlags() throws Exception {
return Task.named("StandardArgs", first, second).ofType(String.class) .process(() -> second + " " + first * 100);
10,680
assertThat(parsedEnum, is(CustomEnum.BAR)); } @RootTask public static Task<String> enums(CustomEnum enm) { parsedEnum = enm; <BUG>return Task.ofType(String.class).named("Enums", enm) .process(enm::toString);</BUG> } @Test public void shouldParseCustomTypes() throws Exception {
return Task.named("Enums", enm).ofType(String.class) .process(enm::toString);
10,681
assertThat(parsedType.content, is("blarg parsed for you!")); } @RootTask public static Task<String> customType(CustomType myType) { parsedType = myType; <BUG>return Task.ofType(String.class).named("Types", myType.content) .process(() -> myType.content);</BUG> } public enum CustomEnum { BAR
return Task.named("Types", myType.content).ofType(String.class) .process(() -> myType.content);
10,682
TaskContext taskContext = TaskContext.inmem(); TaskContext.Value<Long> value = taskContext.evaluate(fib92); value.consume(f92 -> System.out.println("fib(92) = " + f92)); } static Task<Long> create(long n) { <BUG>TaskBuilder<Long> fib = Task.ofType(Long.class).named("Fib", n); </BUG> if (n < 2) { return fib .process(() ...
TaskBuilder<Long> fib = Task.named("Fib", n).ofType(Long.class);
10,683
PARAM_ANNOTATIONS.put("header", HeaderParam.class); PARAM_ANNOTATIONS.put("query", QueryParam.class); PARAM_ANNOTATIONS.put("matrix", MatrixParam.class); } private Comparator<String> importsComparator; <BUG>private boolean generateInterfaces = true; private Map<String, String> properties;</BUG> public SourceGenerator()...
private boolean generateImpl; private Map<String, String> properties;
10,684
WadlGenerator.WADL_NS, "resource"); if (resourceEls.size() == 0) { throw new IllegalStateException("WADL has no resource elements"); } GrammarInfo gInfo = getGrammarInfo(appElement, schemaElements); <BUG>for (Element resource : resourceEls) { writeResourceClass(resource, typeClassNames, gInfo, src); }</BUG> generateMa...
[DELETED]
10,685
return new GrammarInfo(nsMap, elementTypeMap); } public void generateMainClass(Element resourcesEl, File src) { } private void writeResourceClass(Element rElement, Set<String> typeClassNames, <BUG>GrammarInfo gInfo, File src) { String resourceId = rElement.getAttribute("id");</BUG> String path = rElement.getAttribute("...
GrammarInfo gInfo, File src, boolean interfaceIsGenerated) { String resourceId = rElement.getAttribute("id");
10,686
if (HTTP_METHOD_ANNOTATIONS.containsKey(methodName.toLowerCase())) { writeAnnotation(sbCode, imports, HTTP_METHOD_ANNOTATIONS.get(methodName.toLowerCase()), null, true, true); } else { } <BUG>} List<Element> responseEls = DOMUtils.getChildrenWithName(methodEl, WadlGenerator.WADL_NS, "response"); List<Element> requestEl...
[DELETED]
10,687
private Set<String> createImports() { return importsComparator == null ? new TreeSet<String>() : new TreeSet<String>(importsComparator); } public void setGenerateInterfaces(boolean generateInterfaces) { this.generateInterfaces = generateInterfaces; <BUG>} private static class GrammarInfo {</BUG> private Map<String, Str...
public void setGenerateImplementation(boolean generate) { this.generateImpl = generate; private static class GrammarInfo {
10,688
package de.escalon.hypermedia.spring.sample.test; import com.fasterxml.jackson.annotation.JsonCreator; <BUG>import com.fasterxml.jackson.annotation.JsonProperty; import org.springframework.hateoas.Resource;</BUG> public class Event { public final int id; public final String performer;
import de.escalon.hypermedia.action.Select; import org.springframework.hateoas.Resource;
10,689
public class Event { public final int id; public final String performer; public final String location; private EventStatusType eventStatus; <BUG>private final Resource<CreativeWork> workPerformed; public Event(int id, String performer, CreativeWork workPerformed, String location, EventStatusType eventStatus) {</BUG> th...
private String typicalAgeRange; public Event(int id, String performer, CreativeWork workPerformed, String location, EventStatusType eventStatus) {
10,690
} @JsonCreator public Event(@JsonProperty("performer") String performer, @JsonProperty("workPerformed") CreativeWork workPerformed, @JsonProperty("location") String location, <BUG>@JsonProperty("eventStatus") EventStatusType eventStatus) { this.id = 0;</BUG> this.performer = performer; this.location = location;
@JsonProperty("eventStatus") EventStatusType eventStatus, @JsonProperty("typicalAgeRange") @Select({"7-10", "11-"}) String typicalAgeRange) { this.id = 0;
10,691
if (DataType.isSingleValueType(propertyType)) { final Property property = new Property(beanType, propertyDescriptor.getReadMethod(), propertyDescriptor.getWriteMethod(), propertyDescriptor.getName()); <BUG>Object propertyValue = PropertyUtil.getPropertyValue(currentCallValue, propertyDescriptor); ActionInputParameter p...
MethodParameter methodParameter = new MethodParameter(propertyDescriptor.getWriteMethod(), 0); methodParameter, propertyValue); actionInputParameter.getPossibleValues(methodParameter, actionDescriptor);
10,692
package de.escalon.hypermedia.sample.beans; import com.fasterxml.jackson.annotation.JsonCreator; <BUG>import com.fasterxml.jackson.annotation.JsonProperty; import de.escalon.hypermedia.sample.model.CreativeWork;</BUG> import de.escalon.hypermedia.sample.model.EventStatusType; import org.springframework.hateoas.Resource...
import de.escalon.hypermedia.action.Select; import de.escalon.hypermedia.sample.model.CreativeWork;
10,693
public final Resource<CreativeWork> workPerformed; @JsonCreator public Event(@JsonProperty("performer") String performer, @JsonProperty("workPerformed") CreativeWork workPerformed, @JsonProperty("location") String location, <BUG>@JsonProperty("eventStatus") EventStatusType eventStatus) { </BUG> this.id = 0; this.perfor...
@JsonProperty("eventStatus") @Select() EventStatusType eventStatus) {
10,694
public void testCreatesHtmlFormForPost() throws Exception { MvcResult result = this.mockMvc.perform(get("/events").accept(MediaType.TEXT_HTML)) .andExpect(status().isOk()) .andExpect(content().contentType(MediaType.TEXT_HTML)) .andExpect(xpath("h:html/h:body/h:form[@method='POST']/@action", namespaces).string("http://l...
.andExpect(xpath("//h:form[@name='addEvent']/h:div/h:select[@name='eventStatus']", namespaces).exists()) .andExpect(xpath("//h:form[@name='addEvent']/h:div/h:select[@name='typicalAgeRange']", namespaces).exists()) .andReturn();
10,695
if (DataType.isSingleValueType(parameterType)) { Object propertyValue = getPropertyOrFieldValue(currentCallValue, paramName); ActionInputParameter constructorParamInputParameter = new ActionInputParameter( new MethodParameter(constructor, paramIndex), propertyValue); <BUG>final Object[] possibleValues = new Object[0]; ...
final Object[] possibleValues = actionInputParameter.getPossibleValues( new MethodParameter(constructor, paramIndex), actionDescriptor); if (possibleValues.length > 0) {
10,696
if (DataType.isSingleValueType(propertyType)) { final Property property = new Property(beanType, propertyDescriptor.getReadMethod(), propertyDescriptor.getWriteMethod(), propertyDescriptor.getName()); <BUG>Object propertyValue = getPropertyOrFieldValue(currentCallValue, propertyName); ActionInputParameter propertySette...
MethodParameter methodParameter = new MethodParameter(propertyDescriptor.getWriteMethod(), 0); methodParameter, propertyValue); actionInputParameter.getPossibleValues(methodParameter, actionDescriptor);
10,697
package me.doubledutch.lazyjson; import java.util.*; <BUG>import java.nio.ByteBuffer; import me.doubledutch.lazyjson.compressor.*;</BUG> import java.nio.charset.StandardCharsets; public final class LazyNode{ protected static final byte OBJECT=0;
import java.nio.BufferOverflowException; import me.doubledutch.lazyjson.compressor.*;
10,698
size-=255; } buf.put((byte)size); buf.put(data); } <BUG>protected void writeSegmentValues(char cbuf[], ByteBuffer buf,DictionaryCache dict){ </BUG> if(type==OBJECT || type==ARRAY){ LazyNode next=child; while(next!=null){
protected void writeSegmentValues(char cbuf[], ByteBuffer buf,DictionaryCache dict) throws BufferOverflowException{
10,699
package me.doubledutch.lazyjson; <BUG>import java.nio.ByteBuffer; public class LazyElement{</BUG> protected LazyNode root; protected char[] cbuf; private int length=-1;
import me.doubledutch.lazyjson.compressor.*; import java.nio.BufferOverflowException; public class LazyElement{
10,700
ByteBuffer buf=ByteBuffer.allocate(4096); buf.mark(); DictionaryCache dict=new DictionaryCache(100,2); obj1.writeTemplateValues(buf,dict); buf.reset(); <BUG>LazyObject obj2=LazyObject.readFromTemplate(t,buf,dict); </BUG> assertEquals(obj1.getString("foo"),obj2.getString("foo")); } @Test
LazyObject obj2=(LazyObject)LazyElement.readFromTemplate(t,buf,dict);