id stringlengths 7 14 | test_class dict | test_case dict | focal_class dict | focal_method dict | repository dict |
|---|---|---|---|---|---|
133447770_498 | {
"fields": [
{
"declarator": "ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_AUDIO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n ... | {
"body": "@Test\n public void testSelectingForcedTextTrackMatchesAudioLanguage() throws ExoPlaybackException {\n Format forcedEnglish =\n buildTextFormat(/* id= */ \"forcedEnglish\", /* language= */ \"eng\", C.SELECTION_FLAG_FORCED);\n Format forcedGerman =\n buildTextFormat(/* id= */ \"forcedGe... | {
"fields": [
{
"declarator": "FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f",
"modifier": "private static final",
"original_string": "private static final float FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f;",
"type": "float",
"var_name": "FRACTION_TO_CONSIDER_FULLSCREEN"
},
{
"de... | {
"body": "@Override\n protected final Pair<@NullableType RendererConfiguration[], @NullableType TrackSelection[]>\n selectTracks(\n MappedTrackInfo mappedTrackInfo,\n int[][][] rendererFormatSupports,\n int[] rendererMixedMimeTypeAdaptationSupports)\n throws ExoPlaybackExcep... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_162 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/text/ttml/TtmlRenderUtilTest.java",
"identifier": "TtmlRenderUtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testResolveMergeSingleReferentialStyleIntoInlineStyle() {\n Map<String, TtmlStyle> globalStyles = getGlobalStyles();\n String[] styleIds = {\"s0\"};\n TtmlStyle style = new TtmlStyle();\n style.setBackgroundColor(Color.YELLOW);\n\n TtmlStyle resolved = TtmlRenderUtil.res... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/text/ttml/TtmlRenderUtil.java",
"identifier": "TtmlRenderUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "TtmlRenderUtil.resolveStyle(TtmlStyle style, String[] styleIds,\n Map<String, TtmlSty... | {
"body": "public static TtmlStyle resolveStyle(TtmlStyle style, String[] styleIds,\n Map<String, TtmlStyle> globalStyles) {\n if (style == null && styleIds == null) {\n // No styles at all.\n return null;\n } else if (style == null && styleIds.length == 1) {\n // Only one single referential... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_359 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/source/CompositeSequenceableLoaderTest.java",
"identifier": "CompositeSequenceableLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testGetBufferedPositionUsReturnsEndOfSourceWhenAllLoaderBufferedTillEndOfSource() {\n FakeSequenceableLoader loader1 =\n new FakeSequenceableLoader(\n /* bufferedPositionUs */ C.TIME_END_OF_SOURCE,\n /* nextLoadPositionUs */ C.TIME_END_OF_SOURCE);\n F... | {
"fields": [
{
"declarator": "loaders",
"modifier": "protected final",
"original_string": "protected final SequenceableLoader[] loaders;",
"type": "SequenceableLoader[]",
"var_name": "loaders"
}
],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/source/... | {
"body": "@Override\n public final long getBufferedPositionUs() {\n long bufferedPositionUs = Long.MAX_VALUE;\n for (SequenceableLoader loader : loaders) {\n long loaderBufferedPositionUs = loader.getBufferedPositionUs();\n if (loaderBufferedPositionUs != C.TIME_END_OF_SOURCE) {\n bufferedPos... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_436 | {
"fields": [
{
"declarator": "offlineLicenseHelper",
"modifier": "private",
"original_string": "private OfflineLicenseHelper<?> offlineLicenseHelper;",
"type": "OfflineLicenseHelper<?>",
"var_name": "offlineLicenseHelper"
},
{
"declarator": "mediaDrmCallback",
"m... | {
"body": "@Test\n public void testDownloadLicenseDoesNotFailIfDurationNotAvailable() throws Exception {\n setDefaultStubKeySetId();\n\n byte[] offlineLicenseKeySetId = offlineLicenseHelper.downloadLicense(newDrmInitData());\n\n assertThat(offlineLicenseKeySetId).isNotNull();\n }",
"class_method_signatur... | {
"fields": [
{
"declarator": "DUMMY_DRM_INIT_DATA = new DrmInitData()",
"modifier": "private static final",
"original_string": "private static final DrmInitData DUMMY_DRM_INIT_DATA = new DrmInitData();",
"type": "DrmInitData",
"var_name": "DUMMY_DRM_INIT_DATA"
},
{
"de... | {
"body": "public synchronized byte[] downloadLicense(DrmInitData drmInitData) throws DrmSessionException {\n Assertions.checkArgument(drmInitData != null);\n return blockingKeyRequest(DefaultDrmSessionManager.MODE_DOWNLOAD, null, drmInitData);\n }",
"class_method_signature": "OfflineLicenseHelper.downloadLi... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_318 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void\n initialBitrateEstimateOverwrite_forOffline_whileConnectedToNetwork_doesNotSetInitialEstimate() {\n setActiveNetworkInfo(networkInfoWifi);\n DefaultBandwidthMeter bandwidthMeter =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext())\n ... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_461 | {
"fields": [
{
"declarator": "MAX_DURATION_US = 30 * C.MICROS_PER_SECOND",
"modifier": "public static final",
"original_string": "public static final long MAX_DURATION_US = 30 * C.MICROS_PER_SECOND;",
"type": "long",
"var_name": "MAX_DURATION_US"
}
],
"file": "videoplayer-co... | {
"body": "@Test\n public void getBitratesUsingFutureInfo_formatWithoutBitrate_returnsNoValueForEmpty() {\n FakeMediaChunkIterator iterator1 =\n new FakeMediaChunkIterator(\n /* chunkTimeBoundariesSec= */ new long[] {0, 5}, /* chunkLengths= */ new long[] {10});\n Format format1 = createFormat... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/trackselection/TrackSelectionUtil.java",
"identifier": "TrackSelectionUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "TrackSelectionUtil.TrackSelectionUtil()",
"constructor": true,
"f... | {
"body": "@VisibleForTesting\n /* package */ static int[] getBitratesUsingFutureInfo(\n MediaChunkIterator[] iterators,\n Format[] formats,\n long maxDurationUs,\n @Nullable int[] bitrates) {\n int trackCount = iterators.length;\n Assertions.checkArgument(trackCount == formats.length);\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_174 | {
"fields": [
{
"declarator": "EMPTY_FILE = \"subrip/empty\"",
"modifier": "private static final",
"original_string": "private static final String EMPTY_FILE = \"subrip/empty\";",
"type": "String",
"var_name": "EMPTY_FILE"
},
{
"declarator": "TYPICAL_FILE = \"subrip/typ... | {
"body": "@Test\n public void testDecodeCueWithTag() throws IOException {\n SubripDecoder decoder = new SubripDecoder();\n byte[] bytes =\n TestUtil.getByteArray(ApplicationProvider.getApplicationContext(), TYPICAL_WITH_TAGS);\n SubripSubtitle subtitle = decoder.decode(bytes, bytes.length, false);\n... | {
"fields": [
{
"declarator": "START_FRACTION = 0.08f",
"modifier": "static final",
"original_string": "static final float START_FRACTION = 0.08f;",
"type": "float",
"var_name": "START_FRACTION"
},
{
"declarator": "END_FRACTION = 1 - START_FRACTION",
"modifier": "... | {
"body": "@Override\n protected SubripSubtitle decode(byte[] bytes, int length, boolean reset) {\n ArrayList<Cue> cues = new ArrayList<>();\n LongArray cueTimesUs = new LongArray();\n ParsableByteArray subripData = new ParsableByteArray(bytes, length);\n String currentLine;\n\n while ((currentLine = ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_363 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/source/CompositeSequenceableLoaderTest.java",
"identifier": "CompositeSequenceableLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testContinueLoadingOnlyAllowFurthestBehindLoaderToLoadIfNotBehindPlaybackPosition() {\n FakeSequenceableLoader loader1 =\n new FakeSequenceableLoader(/* bufferedPositionUs */ 1000, /* nextLoadPositionUs */ 2000);\n FakeSequenceableLoader loader2 =\n new FakeSequence... | {
"fields": [
{
"declarator": "loaders",
"modifier": "protected final",
"original_string": "protected final SequenceableLoader[] loaders;",
"type": "SequenceableLoader[]",
"var_name": "loaders"
}
],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/source/... | {
"body": "@Override\n public boolean continueLoading(long positionUs) {\n boolean madeProgress = false;\n boolean madeProgressThisIteration;\n do {\n madeProgressThisIteration = false;\n long nextLoadPositionUs = getNextLoadPositionUs();\n if (nextLoadPositionUs == C.TIME_END_OF_SOURCE) {\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_226 | {
"fields": [
{
"declarator": "TEST_POSITION_US = 123456789012345678L",
"modifier": "private static final",
"original_string": "private static final long TEST_POSITION_US = 123456789012345678L;",
"type": "long",
"var_name": "TEST_POSITION_US"
},
{
"declarator": "SLEEP_T... | {
"body": "@Test\n public void enableRendererMediaClockWithFixedParameters_shouldTriggerCallback()\n throws ExoPlaybackException {\n FakeMediaClockRenderer mediaClockRenderer =\n new MediaClockRenderer(TEST_PLAYBACK_PARAMETERS, /* playbackParametersAreMutable= */ false);\n mediaClock.onRendererEnab... | {
"fields": [
{
"declarator": "standaloneMediaClock",
"modifier": "private final",
"original_string": "private final StandaloneMediaClock standaloneMediaClock;",
"type": "StandaloneMediaClock",
"var_name": "standaloneMediaClock"
},
{
"declarator": "listener",
"mod... | {
"body": "public void onRendererEnabled(Renderer renderer) throws ExoPlaybackException {\n MediaClock rendererMediaClock = renderer.getMediaClock();\n if (rendererMediaClock != null && rendererMediaClock != rendererClock) {\n if (rendererClock != null) {\n throw ExoPlaybackException.createForUnexpe... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_33 | {
"fields": [
{
"declarator": "TEST_URI = \"http://www.google.com\"",
"modifier": "private static final",
"original_string": "private static final String TEST_URI = \"http://www.google.com\";",
"type": "String",
"var_name": "TEST_URI"
},
{
"declarator": "TEST_DATA = new... | {
"body": "@Test\n public void testPeekFully() throws Exception {\n DefaultExtractorInput input = createDefaultExtractorInput();\n byte[] target = new byte[TEST_DATA.length];\n input.peekFully(target, 0, TEST_DATA.length);\n\n // Check that we read the whole of TEST_DATA.\n assertThat(Arrays.equals(TE... | {
"fields": [
{
"declarator": "PEEK_MIN_FREE_SPACE_AFTER_RESIZE = 64 * 1024",
"modifier": "private static final",
"original_string": "private static final int PEEK_MIN_FREE_SPACE_AFTER_RESIZE = 64 * 1024;",
"type": "int",
"var_name": "PEEK_MIN_FREE_SPACE_AFTER_RESIZE"
},
{
... | {
"body": "@Override\n public boolean peekFully(byte[] target, int offset, int length, boolean allowEndOfInput)\n throws IOException, InterruptedException {\n if (!advancePeekPosition(length, allowEndOfInput)) {\n return false;\n }\n System.arraycopy(peekBuffer, peekBufferPosition - length, target... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_334 | {
"fields": [
{
"declarator": "CHANNEL_COUNT_MONO = 1",
"modifier": "private static final",
"original_string": "private static final int CHANNEL_COUNT_MONO = 1;",
"type": "int",
"var_name": "CHANNEL_COUNT_MONO"
},
{
"declarator": "CHANNEL_COUNT_STEREO = 2",
"modif... | {
"body": "@Test\n public void trimsStartAndEndFrames() throws Exception {\n configureDefaultAudioSink(\n CHANNEL_COUNT_STEREO,\n /* trimStartFrames= */ TRIM_100_MS_FRAME_COUNT,\n /* trimEndFrames= */ TRIM_10_MS_FRAME_COUNT);\n defaultAudioSink.handleBuffer(createDefaultSilenceBuffer(), /*... | {
"fields": [
{
"declarator": "MIN_BUFFER_DURATION_US = 250000",
"modifier": "private static final",
"original_string": "private static final long MIN_BUFFER_DURATION_US = 250000;",
"type": "long",
"var_name": "MIN_BUFFER_DURATION_US"
},
{
"declarator": "MAX_BUFFER_DURA... | {
"body": "@Override\n @SuppressWarnings(\"ReferenceEquality\")\n public boolean handleBuffer(ByteBuffer buffer, long presentationTimeUs)\n throws InitializationException, WriteException {\n Assertions.checkArgument(inputBuffer == null || buffer == inputBuffer);\n\n if (pendingConfiguration != null) {\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_271 | {
"fields": [
{
"declarator": "mockCache",
"modifier": "@Mock(answer = Answers.CALLS_REAL_METHODS) private",
"original_string": "@Mock(answer = Answers.CALLS_REAL_METHODS) private AbstractFakeCache mockCache;",
"type": "AbstractFakeCache",
"var_name": "mockCache"
},
{
"... | {
"body": "@Test\n public void testRemove() throws Exception {\n FakeDataSet fakeDataSet = new FakeDataSet().setRandomData(\"test_data\", 100);\n FakeDataSource dataSource = new FakeDataSource(fakeDataSet);\n\n Uri uri = Uri.parse(\"test_data\");\n DataSpec dataSpec = new DataSpec(uri, DataSpec.FLAG_ALLO... | {
"fields": [
{
"declarator": "DEFAULT_BUFFER_SIZE_BYTES = 128 * 1024",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_BUFFER_SIZE_BYTES = 128 * 1024;",
"type": "int",
"var_name": "DEFAULT_BUFFER_SIZE_BYTES"
},
{
"declarator": "DE... | {
"body": "public static void remove(\n DataSpec dataSpec, Cache cache, @Nullable CacheKeyFactory cacheKeyFactory) {\n remove(cache, buildCacheKey(dataSpec, cacheKeyFactory));\n }",
"class_method_signature": "CacheUtil.remove(\n DataSpec dataSpec, Cache cache, @Nullable CacheKeyFactory cacheKeyFactory... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_508 | {
"fields": [
{
"declarator": "MAX_DURATION_MS = 30_000",
"modifier": "private static final",
"original_string": "private static final long MAX_DURATION_MS = 30_000;",
"type": "long",
"var_name": "MAX_DURATION_MS"
}
],
"file": "videoplayer-core/src/test/java/com/google/androi... | {
"body": "@Test\n public void\n getBitrates_useFormatBitrateAsLowerBoundSetTrue_returnsEstimateIfOnlyHigherThanFormat() {\n WindowedTrackBitrateEstimator estimator =\n new WindowedTrackBitrateEstimator(\n MAX_DURATION_MS, MAX_DURATION_MS, /* useFormatBitrateAsLowerBound= */ true);\n Med... | {
"fields": [
{
"declarator": "maxPastDurationUs",
"modifier": "private final",
"original_string": "private final long maxPastDurationUs;",
"type": "long",
"var_name": "maxPastDurationUs"
},
{
"declarator": "maxFutureDurationUs",
"modifier": "private final",
... | {
"body": "@Override\n public int[] getBitrates(\n Format[] formats,\n List<? extends MediaChunk> queue,\n MediaChunkIterator[] iterators,\n @Nullable int[] bitrates) {\n if (maxFutureDurationUs > 0 || maxPastDurationUs > 0) {\n return TrackSelectionUtil.getBitratesUsingPastAndFutureInfo(... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_158 | {
"fields": [
{
"declarator": "SPEED = 1f",
"modifier": "private static final",
"original_string": "private static final float SPEED = 1f;",
"type": "float",
"var_name": "SPEED"
},
{
"declarator": "MIN_BUFFER_US = C.msToUs(DefaultLoadControl.DEFAULT_MIN_BUFFER_MS)",
... | {
"body": "@Test\n public void testStartsPlayback_whenMinBufferSizeReached() {\n createDefaultLoadControl();\n assertThat(loadControl.shouldStartPlayback(MIN_BUFFER_US, SPEED, /* rebuffering= */ false))\n .isTrue();\n }",
"class_method_signature": "DefaultLoadControlTest.testStartsPlayback_whenMinBuf... | {
"fields": [
{
"declarator": "DEFAULT_MIN_BUFFER_MS = 15000",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MIN_BUFFER_MS = 15000;",
"type": "int",
"var_name": "DEFAULT_MIN_BUFFER_MS"
},
{
"declarator": "DEFAULT_MAX_BUFFER_MS = ... | {
"body": "@Override\n public boolean shouldStartPlayback(\n long bufferedDurationUs, float playbackSpeed, boolean rebuffering) {\n bufferedDurationUs = Util.getPlayoutDurationForMediaDuration(bufferedDurationUs, playbackSpeed);\n long minBufferDurationUs = rebuffering ? bufferForPlaybackAfterRebufferUs :... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_322 | {
"fields": [
{
"declarator": "NO_COMMAND_RECEIVED = ~PLAYER_COMMAND_WAIT_FOR_CALLBACK",
"modifier": "private static final",
"original_string": "private static final int NO_COMMAND_RECEIVED = ~PLAYER_COMMAND_WAIT_FOR_CALLBACK;",
"type": "int",
"var_name": "NO_COMMAND_RECEIVED"
},... | {
"body": "@Test\n public void setAudioAttributes_withNullUsage_doesNotManageAudioFocus() {\n // Ensure that NULL audio attributes -> don't manage audio focus\n assertThat(\n audioFocusManager.setAudioAttributes(\n /* audioAttributes= */ null, /* playWhenReady= */ false, Player.STATE_... | {
"fields": [
{
"declarator": "PLAYER_COMMAND_DO_NOT_PLAY = -1",
"modifier": "public static final",
"original_string": "public static final int PLAYER_COMMAND_DO_NOT_PLAY = -1;",
"type": "int",
"var_name": "PLAYER_COMMAND_DO_NOT_PLAY"
},
{
"declarator": "PLAYER_COMMAND_... | {
"body": "@PlayerCommand\n public int setAudioAttributes(\n @Nullable AudioAttributes audioAttributes, boolean playWhenReady, int playerState) {\n if (!Util.areEqual(this.audioAttributes, audioAttributes)) {\n this.audioAttributes = audioAttributes;\n focusGain = convertAudioAttributesToFocusGain(... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_267 | {
"fields": [
{
"declarator": "mockCache",
"modifier": "@Mock(answer = Answers.CALLS_REAL_METHODS) private",
"original_string": "@Mock(answer = Answers.CALLS_REAL_METHODS) private AbstractFakeCache mockCache;",
"type": "AbstractFakeCache",
"var_name": "mockCache"
},
{
"... | {
"body": "@Test\n public void testCacheUnknownLengthPartialCaching() throws Exception {\n FakeDataSet fakeDataSet = new FakeDataSet().newData(\"test_data\")\n .setSimulateUnknownLength(true)\n .appendReadData(TestUtil.buildTestData(100)).endData();\n FakeDataSource dataSource = new FakeDataSourc... | {
"fields": [
{
"declarator": "DEFAULT_BUFFER_SIZE_BYTES = 128 * 1024",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_BUFFER_SIZE_BYTES = 128 * 1024;",
"type": "int",
"var_name": "DEFAULT_BUFFER_SIZE_BYTES"
},
{
"declarator": "DE... | {
"body": "public static void cache(\n DataSpec dataSpec,\n Cache cache,\n @Nullable CacheKeyFactory cacheKeyFactory,\n DataSource upstream,\n @Nullable ProgressListener progressListener,\n @Nullable AtomicBoolean isCanceled)\n throws IOException, InterruptedException {\n cache(\... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_375 | {
"fields": [
{
"declarator": "ALLOCATION_SIZE = 16",
"modifier": "private static final",
"original_string": "private static final int ALLOCATION_SIZE = 16;",
"type": "int",
"var_name": "ALLOCATION_SIZE"
},
{
"declarator": "FORMAT_1 = Format.createSampleFormat(\"1\", \"... | {
"body": "@Test\n public void testAdvanceToBeforeBuffer() {\n writeTestData();\n int skipCount = sampleQueue.advanceTo(SAMPLE_TIMESTAMPS[0] - 1, true, false);\n // Should fail and have no effect.\n assertThat(skipCount).isEqualTo(ADVANCE_FAILED);\n assertReadTestData();\n assertNoSamplesToRead(FOR... | {
"fields": [
{
"declarator": "ADVANCE_FAILED = -1",
"modifier": "public static final",
"original_string": "public static final int ADVANCE_FAILED = -1;",
"type": "int",
"var_name": "ADVANCE_FAILED"
},
{
"declarator": "INITIAL_SCRATCH_SIZE = 32",
"modifier": "priv... | {
"body": "public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) {\n return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer);\n }",
"class_method_signature": "SampleQueue.advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer)",
"constructor":... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_230 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/metadata/emsg/EventMessageEncoderTest.java",
"identifier": "EventMessageEncoderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testEncodeEventStream() throws IOException {\n EventMessage eventMessage =\n new EventMessage(\"urn:test\", \"123\", 3000, 1000403, new byte[] {0, 1, 2, 3, 4});\n byte[] expectedEmsgBody =\n new byte[] {\n 117, 114, 110, 58, 116, 101, 115, 116, 0, // scheme... | {
"fields": [
{
"declarator": "byteArrayOutputStream",
"modifier": "private final",
"original_string": "private final ByteArrayOutputStream byteArrayOutputStream;",
"type": "ByteArrayOutputStream",
"var_name": "byteArrayOutputStream"
},
{
"declarator": "dataOutputStream... | {
"body": "@Nullable\n public byte[] encode(EventMessage eventMessage) {\n byteArrayOutputStream.reset();\n try {\n writeNullTerminatedString(dataOutputStream, eventMessage.schemeIdUri);\n String nonNullValue = eventMessage.value != null ? eventMessage.value : \"\";\n writeNullTerminatedString(d... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_119 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/util/MimeTypesTest.java",
"identifier": "MimeTypesTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testGetMimeTypeFromMp4ObjectType_forInvalidObjectType_returnsNull() {\n assertThat(MimeTypes.getMimeTypeFromMp4ObjectType(0)).isNull();\n assertThat(MimeTypes.getMimeTypeFromMp4ObjectType(0x600)).isNull();\n assertThat(MimeTypes.getMimeTypeFromMp4ObjectType(0x01)).isNull();\n ... | {
"fields": [
{
"declarator": "BASE_TYPE_VIDEO = \"video\"",
"modifier": "public static final",
"original_string": "public static final String BASE_TYPE_VIDEO = \"video\";",
"type": "String",
"var_name": "BASE_TYPE_VIDEO"
},
{
"declarator": "BASE_TYPE_AUDIO = \"audio\""... | {
"body": "@Nullable\n public static String getMimeTypeFromMp4ObjectType(int objectType) {\n switch (objectType) {\n case 0x20:\n return MimeTypes.VIDEO_MP4V;\n case 0x21:\n return MimeTypes.VIDEO_H264;\n case 0x23:\n return MimeTypes.VIDEO_H265;\n case 0x60:\n case 0... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_181 | {
"fields": [
{
"declarator": "TYPICAL_FILE = \"webvtt/typical\"",
"modifier": "private static final",
"original_string": "private static final String TYPICAL_FILE = \"webvtt/typical\";",
"type": "String",
"var_name": "TYPICAL_FILE"
},
{
"declarator": "TYPICAL_WITH_BAD_... | {
"body": "@Test\n public void testDecodeEmpty() throws IOException {\n WebvttDecoder decoder = new WebvttDecoder();\n byte[] bytes = TestUtil.getByteArray(ApplicationProvider.getApplicationContext(), EMPTY_FILE);\n try {\n decoder.decode(bytes, bytes.length, /* reset= */ false);\n fail();\n } ... | {
"fields": [
{
"declarator": "EVENT_NONE = -1",
"modifier": "private static final",
"original_string": "private static final int EVENT_NONE = -1;",
"type": "int",
"var_name": "EVENT_NONE"
},
{
"declarator": "EVENT_END_OF_FILE = 0",
"modifier": "private static fin... | {
"body": "@Override\n protected WebvttSubtitle decode(byte[] bytes, int length, boolean reset)\n throws SubtitleDecoderException {\n parsableWebvttData.reset(bytes, length);\n // Initialization for consistent starting state.\n webvttCueBuilder.reset();\n definedStyles.clear();\n\n // Validate th... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_494 | {
"fields": [
{
"declarator": "ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_AUDIO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n ... | {
"body": "@Test\n public void testSelectTracksExceedingCapabilitiesSelectLowerSampleRate()\n throws Exception {\n Format lowerSampleRateFormat =\n Format.createAudioSampleFormat(\"audioFormat\", MimeTypes.AUDIO_AAC, null, Format.NO_VALUE,\n Format.NO_VALUE, 2, 22050, null, null, 0, null);\... | {
"fields": [
{
"declarator": "FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f",
"modifier": "private static final",
"original_string": "private static final float FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f;",
"type": "float",
"var_name": "FRACTION_TO_CONSIDER_FULLSCREEN"
},
{
"de... | {
"body": "@Override\n protected final Pair<@NullableType RendererConfiguration[], @NullableType TrackSelection[]>\n selectTracks(\n MappedTrackInfo mappedTrackInfo,\n int[][][] rendererFormatSupports,\n int[] rendererMixedMimeTypeAdaptationSupports)\n throws ExoPlaybackExcep... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_247 | {
"fields": [
{
"declarator": "TAG_HEADER = new byte[] {'I', 'D', '3', 4, 0, 0, 0, 0, 0, 0}",
"modifier": "private static final",
"original_string": "private static final byte[] TAG_HEADER = new byte[] {'I', 'D', '3', 4, 0, 0, 0, 0, 0, 0};",
"type": "byte[]",
"var_name": "TAG_HEADER"... | {
"body": "@Test\n public void testDecodeCommentFrame() {\n byte[] rawId3 = buildSingleFrameTag(\"COMM\", new byte[] {ID3_TEXT_ENCODING_UTF_8, 101, 110, 103,\n 100, 101, 115, 99, 114, 105, 112, 116, 105, 111, 110, 0, 116, 101, 120, 116, 0});\n Id3Decoder decoder = new Id3Decoder();\n Metadata metadat... | {
"fields": [
{
"declarator": "NO_FRAMES_PREDICATE =\n (majorVersion, id0, id1, id2, id3) -> false",
"modifier": "public static final",
"original_string": "public static final FramePredicate NO_FRAMES_PREDICATE =\n (majorVersion, id0, id1, id2, id3) -> false;",
"type": "FramePred... | {
"body": "private static @Nullable CommentFrame decodeCommentFrame(ParsableByteArray id3Data, int frameSize)\n throws UnsupportedEncodingException {\n if (frameSize < 4) {\n // Frame is malformed.\n return null;\n }\n\n int encoding = id3Data.readUnsignedByte();\n String charset = getChars... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_302 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void\n defaultInitialBitrateEstimate_for2G_forFastCountry_isGreaterThanEstimateForSlowCountry() {\n setActiveNetworkInfo(networkInfo2g);\n setNetworkCountryIso(FAST_COUNTRY_ISO);\n DefaultBandwidthMeter bandwidthMeterFast =\n new DefaultBandwidthMeter.Builder(Applicatio... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_139 | {
"fields": [
{
"declarator": "TEST_DATA =\n new byte[] {0x0F, (byte) 0xFF, (byte) 0x42, (byte) 0x0F, 0x00, 0x00, 0x00, 0x00}",
"modifier": "private static final",
"original_string": "private static final byte[] TEST_DATA =\n new byte[] {0x0F, (byte) 0xFF, (byte) 0x42, (byte) 0x0F, 0x0... | {
"body": "@Test\n public void testReadEmptyString() {\n byte[] bytes = new byte[0];\n ParsableByteArray parser = new ParsableByteArray(bytes);\n assertThat(parser.readLine()).isNull();\n }",
"class_method_signature": "ParsableByteArrayTest.testReadEmptyString()",
"constructor": false,
"full_signatur... | {
"fields": [
{
"declarator": "data",
"modifier": "public",
"original_string": "public byte[] data;",
"type": "byte[]",
"var_name": "data"
},
{
"declarator": "position",
"modifier": "private",
"original_string": "private int position;",
"type": "int",
... | {
"body": "public @Nullable String readLine() {\n if (bytesLeft() == 0) {\n return null;\n }\n int lineLimit = position;\n while (lineLimit < limit && !Util.isLinebreak(data[lineLimit])) {\n lineLimit++;\n }\n if (lineLimit - position >= 3 && data[position] == (byte) 0xEF\n && data[... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_210 | {
"fields": [
{
"declarator": "NO_SUBTITLE = \"tx3g/no_subtitle\"",
"modifier": "private static final",
"original_string": "private static final String NO_SUBTITLE = \"tx3g/no_subtitle\";",
"type": "String",
"var_name": "NO_SUBTITLE"
},
{
"declarator": "SAMPLE_JUST_TEXT... | {
"body": "@Test\n public void testDecodeWithStylAllDefaults() throws IOException, SubtitleDecoderException {\n Tx3gDecoder decoder = new Tx3gDecoder(Collections.emptyList());\n byte[] bytes =\n TestUtil.getByteArray(\n ApplicationProvider.getApplicationContext(), SAMPLE_WITH_STYL_ALL_DEFAULT... | {
"fields": [
{
"declarator": "BOM_UTF16_BE = '\\uFEFF'",
"modifier": "private static final",
"original_string": "private static final char BOM_UTF16_BE = '\\uFEFF';",
"type": "char",
"var_name": "BOM_UTF16_BE"
},
{
"declarator": "BOM_UTF16_LE = '\\uFFFE'",
"modif... | {
"body": "@Override\n protected Subtitle decode(byte[] bytes, int length, boolean reset)\n throws SubtitleDecoderException {\n parsableByteArray.reset(bytes, length);\n String cueTextString = readSubtitleText(parsableByteArray);\n if (cueTextString.isEmpty()) {\n return Tx3gSubtitle.EMPTY;\n }... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_355 | {
"fields": [
{
"declarator": "mediaSource",
"modifier": "private",
"original_string": "private ConcatenatingMediaSource mediaSource;",
"type": "ConcatenatingMediaSource",
"var_name": "mediaSource"
},
{
"declarator": "testRunner",
"modifier": "private",
"ori... | {
"body": "@Test\n public void testRemoveUnpreparedChildSourceWithLazyPreparation() throws IOException {\n FakeMediaSource[] childSources = createMediaSources(/* count= */ 2);\n mediaSource =\n new ConcatenatingMediaSource(\n /* isAtomic= */ false,\n /* useLazyPreparation= */ true,... | {
"fields": [
{
"declarator": "MSG_ADD = 0",
"modifier": "private static final",
"original_string": "private static final int MSG_ADD = 0;",
"type": "int",
"var_name": "MSG_ADD"
},
{
"declarator": "MSG_REMOVE = 1",
"modifier": "private static final",
"origin... | {
"body": "public final synchronized void removeMediaSource(int index) {\n removePublicMediaSources(index, index + 1, /* handler= */ null, /* onCompletionAction= */ null);\n }",
"class_method_signature": "ConcatenatingMediaSource.removeMediaSource(int index)",
"constructor": false,
"full_signature": "public... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_206 | {
"fields": [
{
"declarator": "FIRST_SUBTITLE_STRING = \"This is the first subtitle.\"",
"modifier": "private static final",
"original_string": "private static final String FIRST_SUBTITLE_STRING = \"This is the first subtitle.\";",
"type": "String",
"var_name": "FIRST_SUBTITLE_STRING... | {
"body": "@Test\n public void testNestedSubtitleText() {\n // Test before first subtitle\n assertSingleCueEmpty(nestedSubtitle.getCues(0));\n assertSingleCueEmpty(nestedSubtitle.getCues(500000));\n assertSingleCueEmpty(nestedSubtitle.getCues(999999));\n\n // Test first subtitle\n assertSingleCueTe... | {
"fields": [
{
"declarator": "cues",
"modifier": "private final",
"original_string": "private final List<WebvttCue> cues;",
"type": "List<WebvttCue>",
"var_name": "cues"
},
{
"declarator": "numCues",
"modifier": "private final",
"original_string": "private ... | {
"body": "@Override\n public List<Cue> getCues(long timeUs) {\n ArrayList<Cue> list = null;\n WebvttCue firstNormalCue = null;\n SpannableStringBuilder normalCueTextBuilder = null;\n\n for (int i = 0; i < numCues; i++) {\n if ((cueTimesUs[i * 2] <= timeUs) && (timeUs < cueTimesUs[i * 2 + 1])) {\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_343 | {
"fields": [
{
"declarator": "mediaSource",
"modifier": "private",
"original_string": "private ConcatenatingMediaSource mediaSource;",
"type": "ConcatenatingMediaSource",
"var_name": "mediaSource"
},
{
"declarator": "testRunner",
"modifier": "private",
"ori... | {
"body": "@Test\n public void testCustomCallbackBeforePreparationAddSingleWithIndex() {\n ConditionVariable runnableInvoked = new ConditionVariable();\n\n DummyMainThread dummyMainThread = new DummyMainThread();\n dummyMainThread.runOnMainThread(\n () ->\n mediaSource.addMediaSource(\n ... | {
"fields": [
{
"declarator": "MSG_ADD = 0",
"modifier": "private static final",
"original_string": "private static final int MSG_ADD = 0;",
"type": "int",
"var_name": "MSG_ADD"
},
{
"declarator": "MSG_REMOVE = 1",
"modifier": "private static final",
"origin... | {
"body": "public final synchronized void addMediaSource(MediaSource mediaSource) {\n addMediaSource(mediaSourcesPublic.size(), mediaSource);\n }",
"class_method_signature": "ConcatenatingMediaSource.addMediaSource(MediaSource mediaSource)",
"constructor": false,
"full_signature": "public final synchronized... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_197 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/text/webvtt/WebvttCueParserTest.java",
"identifier": "WebvttCueParserTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParseEntitiesNotTerminatedNoSpace() throws Exception {\n Spanned text = parseCueText(\"&surenot\");\n assertThat(text.toString()).isEqualTo(\"&surenot\");\n }",
"class_method_signature": "WebvttCueParserTest.testParseEntitiesNotTerminatedNoSpace()",
"constructor": false,... | {
"fields": [
{
"declarator": "CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\")",
"modifier": "public static final",
"original_string": "public static final Pattern CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\");",... | {
"body": "static void parseCueText(String id, String markup, WebvttCue.Builder builder,\n List<WebvttCssStyle> styles) {\n SpannableStringBuilder spannedText = new SpannableStringBuilder();\n ArrayDeque<StartTag> startTagStack = new ArrayDeque<>();\n List<StyleMatch> scratchStyleMatches = new ArrayList... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_482 | {
"fields": [
{
"declarator": "ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_AUDIO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n ... | {
"body": "@Test\n public void testSetParameterWithNonDefaultParameterNotifyInvalidationListener()\n throws Exception {\n Parameters parameters = Parameters.DEFAULT.buildUpon().setPreferredAudioLanguage(\"eng\").build();\n trackSelector.setParameters(parameters);\n verify(invalidationListener).onTrackS... | {
"fields": [
{
"declarator": "FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f",
"modifier": "private static final",
"original_string": "private static final float FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f;",
"type": "float",
"var_name": "FRACTION_TO_CONSIDER_FULLSCREEN"
},
{
"de... | {
"body": "public void setParameters(Parameters parameters) {\n Assertions.checkNotNull(parameters);\n if (!parametersReference.getAndSet(parameters).equals(parameters)) {\n invalidate();\n }\n }",
"class_method_signature": "DefaultTrackSelector.setParameters(Parameters parameters)",
"constructor":... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_178 | {
"fields": [
{
"declarator": "EMPTY = \"ssa/empty\"",
"modifier": "private static final",
"original_string": "private static final String EMPTY = \"ssa/empty\";",
"type": "String",
"var_name": "EMPTY"
},
{
"declarator": "TYPICAL = \"ssa/typical\"",
"modifier": "p... | {
"body": "@Test\n public void testDecodeInvalidTimecodes() throws IOException {\n // Parsing should succeed, parsing the third cue only.\n SsaDecoder decoder = new SsaDecoder();\n byte[] bytes =\n TestUtil.getByteArray(ApplicationProvider.getApplicationContext(), INVALID_TIMECODES);\n SsaSubtitle... | {
"fields": [
{
"declarator": "TAG = \"SsaDecoder\"",
"modifier": "private static final",
"original_string": "private static final String TAG = \"SsaDecoder\";",
"type": "String",
"var_name": "TAG"
},
{
"declarator": "SSA_TIMECODE_PATTERN = Pattern.compile(\n \"(?:... | {
"body": "@Override\n protected SsaSubtitle decode(byte[] bytes, int length, boolean reset) {\n ArrayList<Cue> cues = new ArrayList<>();\n LongArray cueTimesUs = new LongArray();\n\n ParsableByteArray data = new ParsableByteArray(bytes, length);\n if (!haveInitializationData) {\n parseHeader(data);... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_314 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void\n initialBitrateEstimateOverwrite_for3G_whileConnectedToOtherNetwork_doesNotSetInitialEstimate() {\n setActiveNetworkInfo(networkInfoWifi);\n DefaultBandwidthMeter bandwidthMeter =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext())\n ... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_103 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/util/UriUtilTest.java",
"identifier": "UriUtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testResolveNormal() {\n String base = \"http://a/b/c/d;p?q\";\n\n assertThat(resolve(base, \"g:h\")).isEqualTo(\"g:h\");\n assertThat(resolve(base, \"g\")).isEqualTo(\"http://a/b/c/g\");\n assertThat(resolve(base, \"g/\")).isEqualTo(\"http://a/b/c/g/\");\n assertThat(res... | {
"fields": [
{
"declarator": "INDEX_COUNT = 4",
"modifier": "private static final",
"original_string": "private static final int INDEX_COUNT = 4;",
"type": "int",
"var_name": "INDEX_COUNT"
},
{
"declarator": "SCHEME_COLON = 0",
"modifier": "private static final",... | {
"body": "public static String resolve(String baseUri, String referenceUri) {\n StringBuilder uri = new StringBuilder();\n\n // Map null onto empty string, to make the following logic simpler.\n baseUri = baseUri == null ? \"\" : baseUri;\n referenceUri = referenceUri == null ? \"\" : referenceUri;\n\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_416 | {
"fields": [
{
"declarator": "TEST_DOWNLOAD_TYPE = \"downloadType\"",
"modifier": "private static final",
"original_string": "private static final String TEST_DOWNLOAD_TYPE = \"downloadType\";",
"type": "String",
"var_name": "TEST_DOWNLOAD_TYPE"
},
{
"declarator": "TES... | {
"body": "@Test\n public void getPeriodCount_returnsPeriodCount() throws Exception {\n prepareDownloadHelper(downloadHelper);\n\n int periodCount = downloadHelper.getPeriodCount();\n\n assertThat(periodCount).isEqualTo(2);\n }",
"class_method_signature": "DownloadHelperTest.getPeriodCount_returnsPeriodC... | {
"fields": [
{
"declarator": "DEFAULT_TRACK_SELECTOR_PARAMETERS =\n new DefaultTrackSelector.ParametersBuilder().setForceHighestSupportedBitrate(true).build()",
"modifier": "public static final",
"original_string": "public static final DefaultTrackSelector.Parameters DEFAULT_TRACK_SELECTOR... | {
"body": "public int getPeriodCount() {\n if (mediaSource == null) {\n return 0;\n }\n assertPreparedWithMedia();\n return trackGroupArrays.length;\n }",
"class_method_signature": "DownloadHelper.getPeriodCount()",
"constructor": false,
"full_signature": "public int getPeriodCount()",
"iden... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_68 | {
"fields": [
{
"declarator": "XING_FRAME_HEADER_DATA = 0xFFFB3000",
"modifier": "private static final",
"original_string": "private static final int XING_FRAME_HEADER_DATA = 0xFFFB3000;",
"type": "int",
"var_name": "XING_FRAME_HEADER_DATA"
},
{
"declarator": "XING_FRAM... | {
"body": "@Test\n public void testGetTimeUsAtEndOfStream() {\n assertThat(seeker.getTimeUs(STREAM_LENGTH))\n .isEqualTo(STREAM_DURATION_US);\n assertThat(\n seekerWithInputLength.getTimeUs(STREAM_LENGTH))\n .isEqualTo(STREAM_DURATION_US);\n }",
"class_method_signature": "XingSeekerTest... | {
"fields": [
{
"declarator": "TAG = \"XingSeeker\"",
"modifier": "private static final",
"original_string": "private static final String TAG = \"XingSeeker\";",
"type": "String",
"var_name": "TAG"
},
{
"declarator": "dataStartPosition",
"modifier": "private final... | {
"body": "@Override\n public long getTimeUs(long position) {\n long positionOffset = position - dataStartPosition;\n if (!isSeekable() || positionOffset <= xingFrameSize) {\n return 0L;\n }\n long[] tableOfContents = Assertions.checkNotNull(this.tableOfContents);\n double scaledPosition = (posit... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_380 | {
"fields": [
{
"declarator": "ALLOCATION_SIZE = 16",
"modifier": "private static final",
"original_string": "private static final int ALLOCATION_SIZE = 16;",
"type": "int",
"var_name": "ALLOCATION_SIZE"
},
{
"declarator": "FORMAT_1 = Format.createSampleFormat(\"1\", \"... | {
"body": "@Test\n public void testDiscardToEnd() {\n writeTestData();\n // Should discard everything.\n sampleQueue.discardToEnd();\n assertThat(sampleQueue.getFirstIndex()).isEqualTo(8);\n assertThat(sampleQueue.getReadIndex()).isEqualTo(8);\n assertAllocationCount(0);\n // We should still be ... | {
"fields": [
{
"declarator": "ADVANCE_FAILED = -1",
"modifier": "public static final",
"original_string": "public static final int ADVANCE_FAILED = -1;",
"type": "int",
"var_name": "ADVANCE_FAILED"
},
{
"declarator": "INITIAL_SCRATCH_SIZE = 32",
"modifier": "priv... | {
"body": "public void discardToEnd() {\n discardDownstreamTo(metadataQueue.discardToEnd());\n }",
"class_method_signature": "SampleQueue.discardToEnd()",
"constructor": false,
"full_signature": "public void discardToEnd()",
"identifier": "discardToEnd",
"invocations": [
"discardDownstreamTo",
"... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_87 | {
"fields": [
{
"declarator": "TEST_DATA = new byte[] {0x3C, (byte) 0xD2, (byte) 0x5F, (byte) 0x01,\n (byte) 0xFF, (byte) 0x14, (byte) 0x60, (byte) 0x99}",
"modifier": "private static final",
"original_string": "private static final byte[] TEST_DATA = new byte[] {0x3C, (byte) 0xD2, (byte) 0... | {
"body": "@Test\n public void testSetPositionByteAligned() {\n testArray.setPosition(16);\n assertReadBitsToEnd(16);\n }",
"class_method_signature": "ParsableBitArrayTest.testSetPositionByteAligned()",
"constructor": false,
"full_signature": "@Test public void testSetPositionByteAligned()",
"identifi... | {
"fields": [
{
"declarator": "data",
"modifier": "public",
"original_string": "public byte[] data;",
"type": "byte[]",
"var_name": "data"
},
{
"declarator": "byteOffset",
"modifier": "private",
"original_string": "private int byteOffset;",
"type": "in... | {
"body": "public void setPosition(int position) {\n byteOffset = position / 8;\n bitOffset = position - (byteOffset * 8);\n assertValidOffset();\n }",
"class_method_signature": "ParsableBitArray.setPosition(int position)",
"constructor": false,
"full_signature": "public void setPosition(int position)... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_7 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/extractor/ogg/VorbisUtilTest.java",
"identifier": "VorbisUtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testVerifyVorbisHeaderCapturePatternInvalidPattern() {\n ParsableByteArray header = new ParsableByteArray(\n new byte[] {0x01, 'x', 'v', 'o', 'r', 'b', 'i', 's'});\n try {\n VorbisUtil.verifyVorbisHeaderCapturePattern(0x01, header, false);\n fail();\n } catch ... | {
"fields": [
{
"declarator": "TAG = \"VorbisUtil\"",
"modifier": "private static final",
"original_string": "private static final String TAG = \"VorbisUtil\";",
"type": "String",
"var_name": "TAG"
}
],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/ext... | {
"body": "public static boolean verifyVorbisHeaderCapturePattern(int headerType, ParsableByteArray header,\n boolean quiet)\n throws ParserException {\n if (header.bytesLeft() < 7) {\n if (quiet) {\n return false;\n } else {\n throw new ParserException(\"too short header: \" + he... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_154 | {
"fields": [
{
"declarator": "SPEED = 1f",
"modifier": "private static final",
"original_string": "private static final float SPEED = 1f;",
"type": "float",
"var_name": "SPEED"
},
{
"declarator": "MIN_BUFFER_US = C.msToUs(DefaultLoadControl.DEFAULT_MIN_BUFFER_MS)",
... | {
"body": "@Test\n public void testShouldContinueLoadingWithTargetBufferBytesReached_untilMinBufferReached() {\n createDefaultLoadControl();\n makeSureTargetBufferBytesReached();\n\n assertThat(loadControl.shouldContinueLoading(/* bufferedDurationUs= */ 0, SPEED)).isTrue();\n assertThat(loadControl.shoul... | {
"fields": [
{
"declarator": "DEFAULT_MIN_BUFFER_MS = 15000",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MIN_BUFFER_MS = 15000;",
"type": "int",
"var_name": "DEFAULT_MIN_BUFFER_MS"
},
{
"declarator": "DEFAULT_MAX_BUFFER_MS = ... | {
"body": "@Override\n public boolean shouldContinueLoading(long bufferedDurationUs, float playbackSpeed) {\n boolean targetBufferSizeReached = allocator.getTotalBytesAllocated() >= targetBufferSize;\n long minBufferUs = hasVideo ? minBufferVideoUs : minBufferAudioUs;\n if (playbackSpeed > 1) {\n // Th... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_504 | {
"fields": [
{
"declarator": "THREE_EMPTY_MEDIA_CHUNK_ITERATORS =\n new MediaChunkIterator[] {\n MediaChunkIterator.EMPTY, MediaChunkIterator.EMPTY, MediaChunkIterator.EMPTY\n }",
"modifier": "private static final",
"original_string": "private static final MediaChunkIterator[] ... | {
"body": "@Test\n public void testEvaluateQueueSizeRetainMoreThanMinimumDurationAfterDiscard() {\n Format format1 = videoFormat(/* bitrate= */ 500, /* width= */ 320, /* height= */ 240);\n Format format2 = videoFormat(/* bitrate= */ 1000, /* width= */ 640, /* height= */ 480);\n Format format3 = videoFormat(... | {
"fields": [
{
"declarator": "DEFAULT_MIN_DURATION_FOR_QUALITY_INCREASE_MS = 10000",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MIN_DURATION_FOR_QUALITY_INCREASE_MS = 10000;",
"type": "int",
"var_name": "DEFAULT_MIN_DURATION_FOR_QUALITY_IN... | {
"body": "@Override\n public int evaluateQueueSize(long playbackPositionUs, List<? extends MediaChunk> queue) {\n long nowMs = clock.elapsedRealtime();\n if (!shouldEvaluateQueueSize(nowMs)) {\n return queue.size();\n }\n\n lastBufferEvaluationMs = nowMs;\n if (queue.isEmpty()) {\n return 0... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_292 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void defaultInitialBitrateEstimate_forWifi_isGreaterThanEstimateFor2G() {\n setActiveNetworkInfo(networkInfoWifi);\n DefaultBandwidthMeter bandwidthMeterWifi =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext()).build();\n long initialEstimateWif... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_338 | {
"fields": [
{
"declarator": "FORMAT = Format.createSampleFormat(null, MimeTypes.AUDIO_RAW, 0)",
"modifier": "private static final",
"original_string": "private static final Format FORMAT = Format.createSampleFormat(null, MimeTypes.AUDIO_RAW, 0);",
"type": "Format",
"var_name": "FOR... | {
"body": "@Config(sdk = 21)\n @Test\n public void testSupportsFormatAtApi21() {\n // From API 21, tunneling is supported.\n assertThat(audioRenderer.supportsFormat(FORMAT))\n .isEqualTo(ADAPTIVE_NOT_SEAMLESS | TUNNELING_SUPPORTED | FORMAT_HANDLED);\n }",
"class_method_signature": "SimpleDecoderAudi... | {
"fields": [
{
"declarator": "REINITIALIZATION_STATE_NONE = 0",
"modifier": "private static final",
"original_string": "private static final int REINITIALIZATION_STATE_NONE = 0;",
"type": "int",
"var_name": "REINITIALIZATION_STATE_NONE"
},
{
"declarator": "REINITIALIZA... | {
"body": "@Override\n public final int supportsFormat(Format format) {\n if (!MimeTypes.isAudio(format.sampleMimeType)) {\n return FORMAT_UNSUPPORTED_TYPE;\n }\n int formatSupport = supportsFormatInternal(drmSessionManager, format);\n if (formatSupport <= FORMAT_UNSUPPORTED_DRM) {\n return for... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_512 | {
"fields": [
{
"declarator": "VIDEO_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_VIDEO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities VIDEO_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_VIDEO);",
"t... | {
"body": "@Test\n public void testMappingMulti() throws ExoPlaybackException {\n FakeMappingTrackSelector trackSelector = new FakeMappingTrackSelector();\n TrackGroupArray multiTrackGroups = new TrackGroupArray(VIDEO_TRACK_GROUP, AUDIO_TRACK_GROUP,\n VIDEO_TRACK_GROUP);\n trackSelector.selectTracks(... | {
"fields": [
{
"declarator": "currentMappedTrackInfo",
"modifier": "private @Nullable",
"original_string": "private @Nullable MappedTrackInfo currentMappedTrackInfo;",
"type": "MappedTrackInfo",
"var_name": "currentMappedTrackInfo"
}
],
"file": "videoplayer-core/src/main/jav... | {
"body": "@Override\n public final TrackSelectorResult selectTracks(\n RendererCapabilities[] rendererCapabilities,\n TrackGroupArray trackGroups,\n MediaPeriodId periodId,\n Timeline timeline)\n throws ExoPlaybackException {\n // Structures into which data will be written during the sel... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_142 | {
"fields": [
{
"declarator": "TEST_DATA =\n new byte[] {0x0F, (byte) 0xFF, (byte) 0x42, (byte) 0x0F, 0x00, 0x00, 0x00, 0x00}",
"modifier": "private static final",
"original_string": "private static final byte[] TEST_DATA =\n new byte[] {0x0F, (byte) 0xFF, (byte) 0x42, (byte) 0x0F, 0x0... | {
"body": "@Test\n public void testReadSingleLineWithoutEndingTrail() {\n byte[] bytes = new byte[] {\n 'f', 'o', 'o'\n };\n ParsableByteArray parser = new ParsableByteArray(bytes);\n assertThat(parser.readLine()).isEqualTo(\"foo\");\n assertThat(parser.readLine()).isNull();\n }",
"class_metho... | {
"fields": [
{
"declarator": "data",
"modifier": "public",
"original_string": "public byte[] data;",
"type": "byte[]",
"var_name": "data"
},
{
"declarator": "position",
"modifier": "private",
"original_string": "private int position;",
"type": "int",
... | {
"body": "public @Nullable String readLine() {\n if (bytesLeft() == 0) {\n return null;\n }\n int lineLimit = position;\n while (lineLimit < limit && !Util.isLinebreak(data[lineLimit])) {\n lineLimit++;\n }\n if (lineLimit - position >= 3 && data[position] == (byte) 0xEF\n && data[... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_457 | {
"fields": [
{
"declarator": "MAX_DURATION_US = 30 * C.MICROS_PER_SECOND",
"modifier": "public static final",
"original_string": "public static final long MAX_DURATION_US = 30 * C.MICROS_PER_SECOND;",
"type": "long",
"var_name": "MAX_DURATION_US"
}
],
"file": "videoplayer-co... | {
"body": "@Test\n public void getBitratesUsingFutureInfo_twoTracksZeroMaxDuration_returnsNoValue() {\n FakeMediaChunkIterator iterator1 =\n new FakeMediaChunkIterator(\n /* chunkTimeBoundariesSec= */ new long[] {0, 10}, /* chunkLengths= */ new long[] {10});\n FakeMediaChunkIterator iterator2... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/trackselection/TrackSelectionUtil.java",
"identifier": "TrackSelectionUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "TrackSelectionUtil.TrackSelectionUtil()",
"constructor": true,
"f... | {
"body": "@VisibleForTesting\n /* package */ static int[] getBitratesUsingFutureInfo(\n MediaChunkIterator[] iterators,\n Format[] formats,\n long maxDurationUs,\n @Nullable int[] bitrates) {\n int trackCount = iterators.length;\n Assertions.checkArgument(trackCount == formats.length);\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_29 | {
"fields": [
{
"declarator": "TEST_URI = \"http://www.google.com\"",
"modifier": "private static final",
"original_string": "private static final String TEST_URI = \"http://www.google.com\";",
"type": "String",
"var_name": "TEST_URI"
},
{
"declarator": "TEST_DATA = new... | {
"body": "@Test\n public void testInitialPosition() throws Exception {\n FakeDataSource testDataSource = buildDataSource();\n DefaultExtractorInput input =\n new DefaultExtractorInput(testDataSource, 123, C.LENGTH_UNSET);\n assertThat(input.getPosition()).isEqualTo(123);\n }",
"class_method_signa... | {
"fields": [
{
"declarator": "PEEK_MIN_FREE_SPACE_AFTER_RESIZE = 64 * 1024",
"modifier": "private static final",
"original_string": "private static final int PEEK_MIN_FREE_SPACE_AFTER_RESIZE = 64 * 1024;",
"type": "int",
"var_name": "PEEK_MIN_FREE_SPACE_AFTER_RESIZE"
},
{
... | {
"body": "@Override\n public long getPosition() {\n return position;\n }",
"class_method_signature": "DefaultExtractorInput.getPosition()",
"constructor": false,
"full_signature": "@Override public long getPosition()",
"identifier": "getPosition",
"invocations": [],
"modifiers": "@Override public",
... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_400 | {
"fields": [
{
"declarator": "ASSERT_TRUE_TIMEOUT = 10000",
"modifier": "private static final",
"original_string": "private static final int ASSERT_TRUE_TIMEOUT = 10000;",
"type": "int",
"var_name": "ASSERT_TRUE_TIMEOUT"
},
{
"declarator": "ASSERT_FALSE_TIME = 1000",
... | {
"body": "@Test\n public void getCurrentDownloads_returnsCurrentDownloads() {\n TaskWrapper task1 = new DownloadRunner(uri1).postDownloadRequest().getTask();\n TaskWrapper task2 = new DownloadRunner(uri2).postDownloadRequest().getTask();\n TaskWrapper task3 =\n new DownloadRunner(uri3).postDownloadR... | {
"fields": [
{
"declarator": "DEFAULT_MAX_PARALLEL_DOWNLOADS = 3",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MAX_PARALLEL_DOWNLOADS = 3;",
"type": "int",
"var_name": "DEFAULT_MAX_PARALLEL_DOWNLOADS"
},
{
"declarator": "DEFAU... | {
"body": "public List<Download> getCurrentDownloads() {\n return downloads;\n }",
"class_method_signature": "DownloadManager.getCurrentDownloads()",
"constructor": false,
"full_signature": "public List<Download> getCurrentDownloads()",
"identifier": "getCurrentDownloads",
"invocations": [],
"modifier... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_379 | {
"fields": [
{
"declarator": "ALLOCATION_SIZE = 16",
"modifier": "private static final",
"original_string": "private static final int ALLOCATION_SIZE = 16;",
"type": "int",
"var_name": "ALLOCATION_SIZE"
},
{
"declarator": "FORMAT_1 = Format.createSampleFormat(\"1\", \"... | {
"body": "@Test\n public void testAdvanceToAfterBufferAllowed() {\n writeTestData();\n int skipCount = sampleQueue.advanceTo(LAST_SAMPLE_TIMESTAMP + 1, true, true);\n // Should succeed and skip to 2nd keyframe (the 4th frame).\n assertThat(skipCount).isEqualTo(4);\n assertReadTestData(null, DATA_SECO... | {
"fields": [
{
"declarator": "ADVANCE_FAILED = -1",
"modifier": "public static final",
"original_string": "public static final int ADVANCE_FAILED = -1;",
"type": "int",
"var_name": "ADVANCE_FAILED"
},
{
"declarator": "INITIAL_SCRATCH_SIZE = 32",
"modifier": "priv... | {
"body": "public int advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer) {\n return metadataQueue.advanceTo(timeUs, toKeyframe, allowTimeBeyondBuffer);\n }",
"class_method_signature": "SampleQueue.advanceTo(long timeUs, boolean toKeyframe, boolean allowTimeBeyondBuffer)",
"constructor":... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_91 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/util/UtilTest.java",
"identifier": "UtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testInferContentType() {\n assertThat(Util.inferContentType(\"http://a.b/c.ism\")).isEqualTo(C.TYPE_SS);\n assertThat(Util.inferContentType(\"http://a.b/c.isml\")).isEqualTo(C.TYPE_SS);\n assertThat(Util.inferContentType(\"http://a.b/c.ism/Manifest\")).isEqualTo(C.TYPE_SS);\n ... | {
"fields": [
{
"declarator": "SDK_INT = Build.VERSION.SDK_INT",
"modifier": "public static final",
"original_string": "public static final int SDK_INT = Build.VERSION.SDK_INT;",
"type": "int",
"var_name": "SDK_INT"
},
{
"declarator": "DEVICE = Build.DEVICE",
"mod... | {
"body": "@C.ContentType\n public static int inferContentType(Uri uri, String overrideExtension) {\n return TextUtils.isEmpty(overrideExtension)\n ? inferContentType(uri)\n : inferContentType(\".\" + overrideExtension);\n }",
"class_method_signature": "Util.inferContentType(Uri uri, String overr... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_396 | {
"fields": [
{
"declarator": "ASSERT_TRUE_TIMEOUT = 10000",
"modifier": "private static final",
"original_string": "private static final int ASSERT_TRUE_TIMEOUT = 10000;",
"type": "int",
"var_name": "ASSERT_TRUE_TIMEOUT"
},
{
"declarator": "ASSERT_FALSE_TIME = 1000",
... | {
"body": "@Test\n public void postDownloadRequest_downloads() throws Throwable {\n DownloadRunner runner = new DownloadRunner(uri1);\n TaskWrapper task = runner.postDownloadRequest().getTask();\n task.assertDownloading();\n runner.getDownloader(0).unblock().assertReleased().assertStartCount(1);\n tas... | {
"fields": [
{
"declarator": "DEFAULT_MAX_PARALLEL_DOWNLOADS = 3",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MAX_PARALLEL_DOWNLOADS = 3;",
"type": "int",
"var_name": "DEFAULT_MAX_PARALLEL_DOWNLOADS"
},
{
"declarator": "DEFAU... | {
"body": "public List<Download> getCurrentDownloads() {\n return downloads;\n }",
"class_method_signature": "DownloadManager.getCurrentDownloads()",
"constructor": false,
"full_signature": "public List<Download> getCurrentDownloads()",
"identifier": "getCurrentDownloads",
"invocations": [],
"modifier... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_372 | {
"fields": [
{
"declarator": "ALLOCATION_SIZE = 16",
"modifier": "private static final",
"original_string": "private static final int ALLOCATION_SIZE = 16;",
"type": "int",
"var_name": "ALLOCATION_SIZE"
},
{
"declarator": "FORMAT_1 = Format.createSampleFormat(\"1\", \"... | {
"body": "@Test\n public void testReadFormatDeduplicated() {\n sampleQueue.format(FORMAT_1);\n assertReadFormat(false, FORMAT_1);\n // If the same format is input then it should be de-duplicated (i.e. not output again).\n sampleQueue.format(FORMAT_1);\n assertNoSamplesToRead(FORMAT_1);\n // The sa... | {
"fields": [
{
"declarator": "ADVANCE_FAILED = -1",
"modifier": "public static final",
"original_string": "public static final int ADVANCE_FAILED = -1;",
"type": "int",
"var_name": "ADVANCE_FAILED"
},
{
"declarator": "INITIAL_SCRATCH_SIZE = 32",
"modifier": "priv... | {
"body": "@Override\n public void format(Format format) {\n Format adjustedFormat = getAdjustedSampleFormat(format, sampleOffsetUs);\n boolean formatChanged = metadataQueue.format(adjustedFormat);\n lastUnadjustedFormat = format;\n pendingFormatAdjustment = false;\n if (upstreamFormatChangeListener !... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_237 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/metadata/icy/IcyDecoderTest.java",
"identifier": "IcyDecoderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void decode_notIcy() {\n IcyDecoder decoder = new IcyDecoder();\n Metadata metadata = decoder.decode(\"NotIcyData\");\n\n assertThat(metadata).isNull();\n }",
"class_method_signature": "IcyDecoderTest.decode_notIcy()",
"constructor": false,
"full_signature": "@Test public vo... | {
"fields": [
{
"declarator": "TAG = \"IcyDecoder\"",
"modifier": "private static final",
"original_string": "private static final String TAG = \"IcyDecoder\";",
"type": "String",
"var_name": "TAG"
},
{
"declarator": "METADATA_ELEMENT = Pattern.compile(\"(.+?)='(.+?)';\... | {
"body": "@Override\n @Nullable\n @SuppressWarnings(\"ByteBufferBackingArray\")\n public Metadata decode(MetadataInputBuffer inputBuffer) {\n ByteBuffer buffer = inputBuffer.data;\n byte[] data = buffer.array();\n int length = buffer.limit();\n return decode(Util.fromUtf8Bytes(data, 0, length));\n }"... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_325 | {
"fields": [
{
"declarator": "NO_COMMAND_RECEIVED = ~PLAYER_COMMAND_WAIT_FOR_CALLBACK",
"modifier": "private static final",
"original_string": "private static final int NO_COMMAND_RECEIVED = ~PLAYER_COMMAND_WAIT_FOR_CALLBACK;",
"type": "int",
"var_name": "NO_COMMAND_RECEIVED"
},... | {
"body": "@Test\n public void setAudioAttributes_withUsageAlarm_throwsIllegalArgumentException() {\n // Ensure that audio attributes that map to AUDIOFOCUS_GAIN_TRANSIENT* throw\n AudioAttributes alarm = new AudioAttributes.Builder().setUsage(C.USAGE_ALARM).build();\n try {\n audioFocusManager.setAudi... | {
"fields": [
{
"declarator": "PLAYER_COMMAND_DO_NOT_PLAY = -1",
"modifier": "public static final",
"original_string": "public static final int PLAYER_COMMAND_DO_NOT_PLAY = -1;",
"type": "int",
"var_name": "PLAYER_COMMAND_DO_NOT_PLAY"
},
{
"declarator": "PLAYER_COMMAND_... | {
"body": "@PlayerCommand\n public int setAudioAttributes(\n @Nullable AudioAttributes audioAttributes, boolean playWhenReady, int playerState) {\n if (!Util.areEqual(this.audioAttributes, audioAttributes)) {\n this.audioAttributes = audioAttributes;\n focusGain = convertAudioAttributesToFocusGain(... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_260 | {
"fields": [
{
"declarator": "mockCache",
"modifier": "@Mock(answer = Answers.CALLS_REAL_METHODS) private",
"original_string": "@Mock(answer = Answers.CALLS_REAL_METHODS) private AbstractFakeCache mockCache;",
"type": "AbstractFakeCache",
"var_name": "mockCache"
},
{
"... | {
"body": "@Test\n public void testGetCachedDataUnknownLength() {\n // Mock there is 100 bytes cached at the beginning\n mockCache.spansAndGaps = new int[] {100};\n Pair<Long, Long> contentLengthAndBytesCached =\n CacheUtil.getCached(\n new DataSpec(Uri.parse(\"test\")), mockCache, /* cach... | {
"fields": [
{
"declarator": "DEFAULT_BUFFER_SIZE_BYTES = 128 * 1024",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_BUFFER_SIZE_BYTES = 128 * 1024;",
"type": "int",
"var_name": "DEFAULT_BUFFER_SIZE_BYTES"
},
{
"declarator": "DE... | {
"body": "public static Pair<Long, Long> getCached(\n DataSpec dataSpec, Cache cache, @Nullable CacheKeyFactory cacheKeyFactory) {\n String key = buildCacheKey(dataSpec, cacheKeyFactory);\n long position = dataSpec.absoluteStreamPosition;\n long requestLength;\n if (dataSpec.length != C.LENGTH_UNSET... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_333 | {
"fields": [
{
"declarator": "CHANNEL_COUNT_MONO = 1",
"modifier": "private static final",
"original_string": "private static final int CHANNEL_COUNT_MONO = 1;",
"type": "int",
"var_name": "CHANNEL_COUNT_MONO"
},
{
"declarator": "CHANNEL_COUNT_STEREO = 2",
"modif... | {
"body": "@Test\n public void trimsEndFrames() throws Exception {\n configureDefaultAudioSink(\n CHANNEL_COUNT_STEREO,\n /* trimStartFrames= */ 0,\n /* trimEndFrames= */ TRIM_10_MS_FRAME_COUNT);\n defaultAudioSink.handleBuffer(createDefaultSilenceBuffer(), /* presentationTimeUs= */ 0);\n\... | {
"fields": [
{
"declarator": "MIN_BUFFER_DURATION_US = 250000",
"modifier": "private static final",
"original_string": "private static final long MIN_BUFFER_DURATION_US = 250000;",
"type": "long",
"var_name": "MIN_BUFFER_DURATION_US"
},
{
"declarator": "MAX_BUFFER_DURA... | {
"body": "@Override\n @SuppressWarnings(\"ReferenceEquality\")\n public boolean handleBuffer(ByteBuffer buffer, long presentationTimeUs)\n throws InitializationException, WriteException {\n Assertions.checkArgument(inputBuffer == null || buffer == inputBuffer);\n\n if (pendingConfiguration != null) {\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_299 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void defaultInitialBitrateEstimate_forOffline_isReasonable() {\n setActiveNetworkInfo(networkInfoOffline);\n DefaultBandwidthMeter bandwidthMeter =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext()).build();\n long initialEstimate = bandwidthMet... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_34 | {
"fields": [
{
"declarator": "TEST_URI = \"http://www.google.com\"",
"modifier": "private static final",
"original_string": "private static final String TEST_URI = \"http://www.google.com\";",
"type": "String",
"var_name": "TEST_URI"
},
{
"declarator": "TEST_DATA = new... | {
"body": "@Test\n public void testResetPeekPosition() throws Exception {\n DefaultExtractorInput input = createDefaultExtractorInput();\n byte[] target = new byte[TEST_DATA.length];\n input.peekFully(target, 0, TEST_DATA.length);\n\n // Check that we read the whole of TEST_DATA.\n assertThat(Arrays.e... | {
"fields": [
{
"declarator": "PEEK_MIN_FREE_SPACE_AFTER_RESIZE = 64 * 1024",
"modifier": "private static final",
"original_string": "private static final int PEEK_MIN_FREE_SPACE_AFTER_RESIZE = 64 * 1024;",
"type": "int",
"var_name": "PEEK_MIN_FREE_SPACE_AFTER_RESIZE"
},
{
... | {
"body": "@Override\n public void resetPeekPosition() {\n peekBufferPosition = 0;\n }",
"class_method_signature": "DefaultExtractorInput.resetPeekPosition()",
"constructor": false,
"full_signature": "@Override public void resetPeekPosition()",
"identifier": "resetPeekPosition",
"invocations": [],
"m... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_276 | {
"fields": [
{
"declarator": "testIndexV1File = {\n 0, 0, 0, 1, // version\n 0, 0, 0, 0, // flags\n 0, 0, 0, 2, // number_of_CachedContent\n 0, 0, 0, 5, // cache_id 5\n 0, 5, 65, 66, 67, 68, 69, // cache_key \"ABCDE\"\n 0, 0, 0, 0, 0, 0, 0, 10, // original_content_length\n ... | {
"body": "@Test\n public void testGetNewId() {\n SparseArray<String> idToKey = new SparseArray<>();\n assertThat(CachedContentIndex.getNewId(idToKey)).isEqualTo(0);\n idToKey.put(10, \"\");\n assertThat(CachedContentIndex.getNewId(idToKey)).isEqualTo(11);\n idToKey.put(Integer.MAX_VALUE, \"\");\n ... | {
"fields": [
{
"declarator": "FILE_NAME_ATOMIC = \"cached_content_index.exi\"",
"modifier": "static final",
"original_string": "static final String FILE_NAME_ATOMIC = \"cached_content_index.exi\";",
"type": "String",
"var_name": "FILE_NAME_ATOMIC"
},
{
"declarator": "I... | {
"body": "@VisibleForTesting\n /* package */ static int getNewId(SparseArray<String> idToKey) {\n int size = idToKey.size();\n int id = size == 0 ? 0 : (idToKey.keyAt(size - 1) + 1);\n if (id < 0) { // In case if we pass max int value.\n // TODO optimization: defragmentation or binary search?\n f... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_108 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/util/UriUtilTest.java",
"identifier": "UriUtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void removeMiddleQueryParameter() {\n Uri uri = Uri.parse(\"http://uri?first=value1&query=value&last=value2\");\n assertThat(removeQueryParameter(uri, \"query\").toString())\n .isEqualTo(\"http://uri?first=value1&last=value2\");\n }",
"class_method_signature": "UriUtilTest.r... | {
"fields": [
{
"declarator": "INDEX_COUNT = 4",
"modifier": "private static final",
"original_string": "private static final int INDEX_COUNT = 4;",
"type": "int",
"var_name": "INDEX_COUNT"
},
{
"declarator": "SCHEME_COLON = 0",
"modifier": "private static final",... | {
"body": "public static Uri removeQueryParameter(Uri uri, String queryParameterName) {\n Uri.Builder builder = uri.buildUpon();\n builder.clearQuery();\n for (String key : uri.getQueryParameterNames()) {\n if (!key.equals(queryParameterName)) {\n for (String value : uri.getQueryParameters(key)) ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_364 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/source/CompositeSequenceableLoaderTest.java",
"identifier": "CompositeSequenceableLoaderTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testContinueLoadingReturnAllowAllLoadersBehindPlaybackPositionToLoad() {\n FakeSequenceableLoader loader1 =\n new FakeSequenceableLoader(/* bufferedPositionUs */ 1000, /* nextLoadPositionUs */ 2000);\n FakeSequenceableLoader loader2 =\n new FakeSequenceableLoader(/*... | {
"fields": [
{
"declarator": "loaders",
"modifier": "protected final",
"original_string": "protected final SequenceableLoader[] loaders;",
"type": "SequenceableLoader[]",
"var_name": "loaders"
}
],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/source/... | {
"body": "@Override\n public boolean continueLoading(long positionUs) {\n boolean madeProgress = false;\n boolean madeProgressThisIteration;\n do {\n madeProgressThisIteration = false;\n long nextLoadPositionUs = getNextLoadPositionUs();\n if (nextLoadPositionUs == C.TIME_END_OF_SOURCE) {\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_221 | {
"fields": [
{
"declarator": "TEST_POSITION_US = 123456789012345678L",
"modifier": "private static final",
"original_string": "private static final long TEST_POSITION_US = 123456789012345678L;",
"type": "long",
"var_name": "TEST_POSITION_US"
},
{
"declarator": "SLEEP_T... | {
"body": "@Test\n public void standaloneStop_shouldKeepClockStopped() throws Exception {\n mediaClock.stop();\n assertClockIsStopped();\n }",
"class_method_signature": "DefaultMediaClockTest.standaloneStop_shouldKeepClockStopped()",
"constructor": false,
"full_signature": "@Test public void standaloneS... | {
"fields": [
{
"declarator": "standaloneMediaClock",
"modifier": "private final",
"original_string": "private final StandaloneMediaClock standaloneMediaClock;",
"type": "StandaloneMediaClock",
"var_name": "standaloneMediaClock"
},
{
"declarator": "listener",
"mod... | {
"body": "public void stop() {\n standaloneMediaClock.stop();\n }",
"class_method_signature": "DefaultMediaClock.stop()",
"constructor": false,
"full_signature": "public void stop()",
"identifier": "stop",
"invocations": [
"stop"
],
"modifiers": "public",
"parameters": "()",
"return": "void... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_466 | {
"fields": [
{
"declarator": "MAX_DURATION_US = 30 * C.MICROS_PER_SECOND",
"modifier": "public static final",
"original_string": "public static final long MAX_DURATION_US = 30 * C.MICROS_PER_SECOND;",
"type": "long",
"var_name": "MAX_DURATION_US"
}
],
"file": "videoplayer-co... | {
"body": "@Test\n public void getBitratesUsingPastInfo_oneChunkWithSameFormat_returnsBitrates() {\n Format format = createFormatWithBitrate(10);\n FakeMediaChunk chunk =\n createChunk(format, /* length= */ 10, /* startTimeSec= */ 0, /* endTimeSec= */ 10);\n\n int[] bitrates =\n TrackSelection... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/trackselection/TrackSelectionUtil.java",
"identifier": "TrackSelectionUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "TrackSelectionUtil.TrackSelectionUtil()",
"constructor": true,
"f... | {
"body": "@VisibleForTesting\n /* package */ static int[] getBitratesUsingPastInfo(\n List<? extends MediaChunk> queue,\n Format[] formats,\n long maxDurationUs,\n @Nullable int[] bitrates) {\n if (bitrates == null) {\n bitrates = new int[formats.length];\n Arrays.fill(bitrates, For... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_489 | {
"fields": [
{
"declarator": "ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_AUDIO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n ... | {
"body": "@Test\n public void testSelectTracksWithinCapabilitiesSelectHigherSampleRate()\n throws Exception {\n Format higherSampleRateFormat =\n Format.createAudioSampleFormat(\"audioFormat\", MimeTypes.AUDIO_AAC, null, Format.NO_VALUE,\n Format.NO_VALUE, 2, 44100, null, null, 0, null);\n... | {
"fields": [
{
"declarator": "FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f",
"modifier": "private static final",
"original_string": "private static final float FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f;",
"type": "float",
"var_name": "FRACTION_TO_CONSIDER_FULLSCREEN"
},
{
"de... | {
"body": "@Override\n protected final Pair<@NullableType RendererConfiguration[], @NullableType TrackSelection[]>\n selectTracks(\n MappedTrackInfo mappedTrackInfo,\n int[][][] rendererFormatSupports,\n int[] rendererMixedMimeTypeAdaptationSupports)\n throws ExoPlaybackExcep... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_173 | {
"fields": [
{
"declarator": "EMPTY_FILE = \"subrip/empty\"",
"modifier": "private static final",
"original_string": "private static final String EMPTY_FILE = \"subrip/empty\";",
"type": "String",
"var_name": "EMPTY_FILE"
},
{
"declarator": "TYPICAL_FILE = \"subrip/typ... | {
"body": "@Test\n public void testDecodeNoEndTimecodes() throws IOException {\n SubripDecoder decoder = new SubripDecoder();\n byte[] bytes =\n TestUtil.getByteArray(ApplicationProvider.getApplicationContext(), NO_END_TIMECODES_FILE);\n SubripSubtitle subtitle = decoder.decode(bytes, bytes.length, f... | {
"fields": [
{
"declarator": "START_FRACTION = 0.08f",
"modifier": "static final",
"original_string": "static final float START_FRACTION = 0.08f;",
"type": "float",
"var_name": "START_FRACTION"
},
{
"declarator": "END_FRACTION = 1 - START_FRACTION",
"modifier": "... | {
"body": "@Override\n protected SubripSubtitle decode(byte[] bytes, int length, boolean reset) {\n ArrayList<Cue> cues = new ArrayList<>();\n LongArray cueTimesUs = new LongArray();\n ParsableByteArray subripData = new ParsableByteArray(bytes, length);\n String currentLine;\n\n while ((currentLine = ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_18 | {
"fields": [
{
"declarator": "OGG_EXTRACTOR_FACTORY = OggExtractor::new",
"modifier": "private static final",
"original_string": "private static final ExtractorFactory OGG_EXTRACTOR_FACTORY = OggExtractor::new;",
"type": "ExtractorFactory",
"var_name": "OGG_EXTRACTOR_FACTORY"
}
... | {
"body": "@Test\n public void testSniffFailsInvalidOggHeader() throws Exception {\n byte[] data = OggTestData.buildOggHeader(0x00, 0, 1000, 0x00);\n assertThat(sniff(data)).isFalse();\n }",
"class_method_signature": "OggExtractorTest.testSniffFailsInvalidOggHeader()",
"constructor": false,
"full_signat... | {
"fields": [
{
"declarator": "FACTORY = () -> new Extractor[] {new OggExtractor()}",
"modifier": "public static final",
"original_string": "public static final ExtractorsFactory FACTORY = () -> new Extractor[] {new OggExtractor()};",
"type": "ExtractorsFactory",
"var_name": "FACTORY... | {
"body": "@Override\n public boolean sniff(ExtractorInput input) throws IOException, InterruptedException {\n try {\n return sniffInternal(input);\n } catch (ParserException e) {\n return false;\n }\n }",
"class_method_signature": "OggExtractor.sniff(ExtractorInput input)",
"constructor": fa... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_431 | {
"fields": [
{
"declarator": "CONTENT_DURATION_US = 30 * C.MICROS_PER_SECOND",
"modifier": "private static final",
"original_string": "private static final long CONTENT_DURATION_US = 30 * C.MICROS_PER_SECOND;",
"type": "long",
"var_name": "CONTENT_DURATION_US"
},
{
"de... | {
"body": "@Test\n public void\n updateQueuedPeriods_withDurationChangeInReadingPeriodAfterReadingPosition_handlesChangeAndRemovesPeriodsAfterChangedPeriod() {\n setupTimeline(\n /* initialPositionUs= */ 0,\n /* adGroupTimesUs= */ FIRST_AD_START_TIME_US,\n SECOND_AD_START_TIME_US);\n ... | {
"fields": [
{
"declarator": "MAXIMUM_BUFFER_AHEAD_PERIODS = 100",
"modifier": "private static final",
"original_string": "private static final int MAXIMUM_BUFFER_AHEAD_PERIODS = 100;",
"type": "int",
"var_name": "MAXIMUM_BUFFER_AHEAD_PERIODS"
},
{
"declarator": "perio... | {
"body": "public boolean updateQueuedPeriods(long rendererPositionUs, long maxRendererReadPositionUs) {\n // TODO: Merge this into setTimeline so that the queue gets updated as soon as the new timeline\n // is set, once all cases handled by ExoPlayerImplInternal.handleSourceInfoRefreshed can be\n // handled... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_348 | {
"fields": [
{
"declarator": "mediaSource",
"modifier": "private",
"original_string": "private ConcatenatingMediaSource mediaSource;",
"type": "ConcatenatingMediaSource",
"var_name": "mediaSource"
},
{
"declarator": "testRunner",
"modifier": "private",
"ori... | {
"body": "@Test\n public void testCustomCallbackAfterPreparationAddMultipleWithIndex() throws IOException {\n DummyMainThread dummyMainThread = new DummyMainThread();\n try {\n testRunner.prepareSource();\n final TimelineGrabber timelineGrabber = new TimelineGrabber(testRunner);\n dummyMainThre... | {
"fields": [
{
"declarator": "MSG_ADD = 0",
"modifier": "private static final",
"original_string": "private static final int MSG_ADD = 0;",
"type": "int",
"var_name": "MSG_ADD"
},
{
"declarator": "MSG_REMOVE = 1",
"modifier": "private static final",
"origin... | {
"body": "public final synchronized void addMediaSources(Collection<MediaSource> mediaSources) {\n addPublicMediaSources(\n mediaSourcesPublic.size(),\n mediaSources,\n /* handler= */ null,\n /* onCompletionAction= */ null);\n }",
"class_method_signature": "ConcatenatingMediaSource.... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_427 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/offline/StreamKeyTest.java",
"identifier": "StreamKeyTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParcelable() {\n StreamKey streamKeyToParcel = new StreamKey(1, 2, 3);\n Parcel parcel = Parcel.obtain();\n streamKeyToParcel.writeToParcel(parcel, 0);\n parcel.setDataPosition(0);\n\n StreamKey streamKeyFromParcel = StreamKey.CREATOR.createFromParcel(parcel);\n a... | {
"fields": [
{
"declarator": "periodIndex",
"modifier": "public final",
"original_string": "public final int periodIndex;",
"type": "int",
"var_name": "periodIndex"
},
{
"declarator": "groupIndex",
"modifier": "public final",
"original_string": "public fina... | {
"body": "@Override\n public void writeToParcel(Parcel dest, int flags) {\n dest.writeInt(periodIndex);\n dest.writeInt(groupIndex);\n dest.writeInt(trackIndex);\n }",
"class_method_signature": "StreamKey.writeToParcel(Parcel dest, int flags)",
"constructor": false,
"full_signature": "@Override publ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_470 | {
"fields": [
{
"declarator": "MAX_DURATION_US = 30 * C.MICROS_PER_SECOND",
"modifier": "public static final",
"original_string": "public static final long MAX_DURATION_US = 30 * C.MICROS_PER_SECOND;",
"type": "long",
"var_name": "MAX_DURATION_US"
}
],
"file": "videoplayer-co... | {
"body": "@Test\n public void getBitratesUsingPastInfo_trackFormatNoBitrate_returnsNoValue() {\n FakeMediaChunk chunk =\n createChunk(\n createFormatWithBitrate(10),\n /* length= */ 10,\n /* startTimeSec= */ 0,\n /* endTimeSec= */ 10);\n\n int[] bitrates =\n ... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/trackselection/TrackSelectionUtil.java",
"identifier": "TrackSelectionUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "TrackSelectionUtil.TrackSelectionUtil()",
"constructor": true,
"f... | {
"body": "@VisibleForTesting\n /* package */ static int[] getBitratesUsingPastInfo(\n List<? extends MediaChunk> queue,\n Format[] formats,\n long maxDurationUs,\n @Nullable int[] bitrates) {\n if (bitrates == null) {\n bitrates = new int[formats.length];\n Arrays.fill(bitrates, For... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_165 | {
"fields": [
{
"declarator": "EMPTY_FILE = \"subrip/empty\"",
"modifier": "private static final",
"original_string": "private static final String EMPTY_FILE = \"subrip/empty\";",
"type": "String",
"var_name": "EMPTY_FILE"
},
{
"declarator": "TYPICAL_FILE = \"subrip/typ... | {
"body": "@Test\n public void testDecodeEmpty() throws IOException {\n SubripDecoder decoder = new SubripDecoder();\n byte[] bytes = TestUtil.getByteArray(ApplicationProvider.getApplicationContext(), EMPTY_FILE);\n SubripSubtitle subtitle = decoder.decode(bytes, bytes.length, false);\n\n assertThat(subt... | {
"fields": [
{
"declarator": "START_FRACTION = 0.08f",
"modifier": "static final",
"original_string": "static final float START_FRACTION = 0.08f;",
"type": "float",
"var_name": "START_FRACTION"
},
{
"declarator": "END_FRACTION = 1 - START_FRACTION",
"modifier": "... | {
"body": "@Override\n protected SubripSubtitle decode(byte[] bytes, int length, boolean reset) {\n ArrayList<Cue> cues = new ArrayList<>();\n LongArray cueTimesUs = new LongArray();\n ParsableByteArray subripData = new ParsableByteArray(bytes, length);\n String currentLine;\n\n while ((currentLine = ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_309 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void\n initialBitrateEstimateOverwrite_forEthernet_whileConnectedToEthernet_setsInitialEstimate() {\n setActiveNetworkInfo(networkInfoEthernet);\n DefaultBandwidthMeter bandwidthMeter =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext())\n ... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_391 | {
"fields": [
{
"declarator": "tempFile",
"modifier": "private",
"original_string": "private File tempFile;",
"type": "File",
"var_name": "tempFile"
},
{
"declarator": "expectedAction1",
"modifier": "private",
"original_string": "private DownloadRequest expe... | {
"body": "@Test\n public void testLoadIncompleteHeaderThrowsIOException() throws Exception {\n ActionFile actionFile = getActionFile(\"offline/action_file_incomplete_header.exi\");\n try {\n actionFile.load();\n Assert.fail();\n } catch (IOException e) {\n // Expected exception.\n }\n }"... | {
"fields": [
{
"declarator": "VERSION = 0",
"modifier": "private static final",
"original_string": "private static final int VERSION = 0;",
"type": "int",
"var_name": "VERSION"
},
{
"declarator": "atomicFile",
"modifier": "private final",
"original_string":... | {
"body": "public DownloadRequest[] load() throws IOException {\n if (!exists()) {\n return new DownloadRequest[0];\n }\n InputStream inputStream = null;\n try {\n inputStream = atomicFile.openRead();\n DataInputStream dataInputStream = new DataInputStream(inputStream);\n int version =... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_96 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/util/UtilTest.java",
"identifier": "UtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParseXsDuration() {\n assertThat(parseXsDuration(\"PT150.279S\")).isEqualTo(150279L);\n assertThat(parseXsDuration(\"PT1.500S\")).isEqualTo(1500L);\n }",
"class_method_signature": "UtilTest.testParseXsDuration()",
"constructor": false,
"full_signature": "@Test public v... | {
"fields": [
{
"declarator": "SDK_INT = Build.VERSION.SDK_INT",
"modifier": "public static final",
"original_string": "public static final int SDK_INT = Build.VERSION.SDK_INT;",
"type": "int",
"var_name": "SDK_INT"
},
{
"declarator": "DEVICE = Build.DEVICE",
"mod... | {
"body": "public static long parseXsDuration(String value) {\n Matcher matcher = XS_DURATION_PATTERN.matcher(value);\n if (matcher.matches()) {\n boolean negated = !TextUtils.isEmpty(matcher.group(1));\n // Durations containing years and months aren't completely defined. We assume there are\n //... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_407 | {
"fields": [
{
"declarator": "NOW_MS = 1234",
"modifier": "private static final",
"original_string": "private static final long NOW_MS = 1234;",
"type": "long",
"var_name": "NOW_MS"
},
{
"declarator": "tempFile",
"modifier": "private",
"original_string": "p... | {
"body": "@Test\n public void upgradeAndDelete_createsDownloads() throws IOException {\n // Copy the test asset to a file.\n byte[] actionFileBytes =\n TestUtil.getByteArray(\n ApplicationProvider.getApplicationContext(),\n \"offline/action_file_for_download_index_upgrade.exi\");\... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/offline/ActionFileUpgradeUtil.java",
"identifier": "ActionFileUpgradeUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "ActionFileUpgradeUtil.ActionFileUpgradeUtil()",
"constructor": true,
... | {
"body": "@SuppressWarnings(\"deprecation\")\n public static void upgradeAndDelete(\n File actionFilePath,\n @Nullable DownloadIdProvider downloadIdProvider,\n DefaultDownloadIndex downloadIndex,\n boolean deleteOnFailure,\n boolean addNewDownloadsAsCompleted)\n throws IOException {\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_329 | {
"fields": [
{
"declarator": "TRUEHD_SYNCFRAME_SAMPLE_COUNT = 40",
"modifier": "private static final",
"original_string": "private static final int TRUEHD_SYNCFRAME_SAMPLE_COUNT = 40;",
"type": "int",
"var_name": "TRUEHD_SYNCFRAME_SAMPLE_COUNT"
},
{
"declarator": "TRUE... | {
"body": "@Test\n public void testParseTrueHdSyncframeAudioSampleCount_nonSyncframe() {\n assertThat(Ac3Util.parseTrueHdSyncframeAudioSampleCount(TRUEHD_NON_SYNCFRAME_HEADER))\n .isEqualTo(0);\n }",
"class_method_signature": "Ac3UtilTest.testParseTrueHdSyncframeAudioSampleCount_nonSyncframe()",
"cons... | {
"fields": [
{
"declarator": "TRUEHD_RECHUNK_SAMPLE_COUNT = 16",
"modifier": "public static final",
"original_string": "public static final int TRUEHD_RECHUNK_SAMPLE_COUNT = 16;",
"type": "int",
"var_name": "TRUEHD_RECHUNK_SAMPLE_COUNT"
},
{
"declarator": "TRUEHD_SYNCF... | {
"body": "public static int parseTrueHdSyncframeAudioSampleCount(byte[] syncframe) {\n // TODO: Link to specification if available.\n // The syncword ends 0xBA for TrueHD or 0xBB for MLP.\n if (syncframe[4] != (byte) 0xF8\n || syncframe[5] != (byte) 0x72\n || syncframe[6] != (byte) 0x6F\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_145 | {
"fields": [
{
"declarator": "TEST_DATA =\n new byte[] {0x0F, (byte) 0xFF, (byte) 0x42, (byte) 0x0F, 0x00, 0x00, 0x00, 0x00}",
"modifier": "private static final",
"original_string": "private static final byte[] TEST_DATA =\n new byte[] {0x0F, (byte) 0xFF, (byte) 0x42, (byte) 0x0F, 0x0... | {
"body": "@Test\n public void testReadThreeLinesWithEmptyLine() {\n byte[] bytes = new byte[] {\n 'f', 'o', 'o', '\\r', '\\n', '\\r', 'b', 'a', 'r'\n };\n ParsableByteArray parser = new ParsableByteArray(bytes);\n assertThat(parser.readLine()).isEqualTo(\"foo\");\n assertThat(parser.readLine()).... | {
"fields": [
{
"declarator": "data",
"modifier": "public",
"original_string": "public byte[] data;",
"type": "byte[]",
"var_name": "data"
},
{
"declarator": "position",
"modifier": "private",
"original_string": "private int position;",
"type": "int",
... | {
"body": "public @Nullable String readLine() {\n if (bytesLeft() == 0) {\n return null;\n }\n int lineLimit = position;\n while (lineLimit < limit && !Util.isLinebreak(data[lineLimit])) {\n lineLimit++;\n }\n if (lineLimit - position >= 3 && data[position] == (byte) 0xEF\n && data[... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_450 | {
"fields": [
{
"declarator": "MAX_DURATION_US = 30 * C.MICROS_PER_SECOND",
"modifier": "public static final",
"original_string": "public static final long MAX_DURATION_US = 30 * C.MICROS_PER_SECOND;",
"type": "long",
"var_name": "MAX_DURATION_US"
}
],
"file": "videoplayer-co... | {
"body": "@Test\n public void getAverageBitrate_multipleDifferentDurationChunks_returnsAverageChunkBitrate() {\n long[] chunkTimeBoundariesSec = {0, 5, 15, 30};\n long[] chunkLengths = {10, 20, 30};\n\n FakeMediaChunkIterator iterator =\n new FakeMediaChunkIterator(chunkTimeBoundariesSec, chunkLengt... | {
"fields": [],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/trackselection/TrackSelectionUtil.java",
"identifier": "TrackSelectionUtil",
"interfaces": "",
"methods": [
{
"class_method_signature": "TrackSelectionUtil.TrackSelectionUtil()",
"constructor": true,
"f... | {
"body": "public static int getAverageBitrate(MediaChunkIterator iterator, long maxDurationUs) {\n long totalDurationUs = 0;\n long totalLength = 0;\n while (iterator.next()) {\n long chunkLength = iterator.getDataSpec().length;\n if (chunkLength == C.LENGTH_UNSET) {\n break;\n }\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_295 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void defaultInitialBitrateEstimate_forEthernet_isGreaterThanEstimateFor3G() {\n setActiveNetworkInfo(networkInfoEthernet);\n DefaultBandwidthMeter bandwidthMeterEthernet =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext()).build();\n long initia... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_153 | {
"fields": [
{
"declarator": "SPEED = 1f",
"modifier": "private static final",
"original_string": "private static final float SPEED = 1f;",
"type": "float",
"var_name": "SPEED"
},
{
"declarator": "MIN_BUFFER_US = C.msToUs(DefaultLoadControl.DEFAULT_MIN_BUFFER_MS)",
... | {
"body": "@Test\n public void testShouldNotContinueLoadingOnceBufferingStopped_untilBelowMinBuffer() {\n createDefaultLoadControl();\n assertThat(loadControl.shouldContinueLoading(MAX_BUFFER_US, SPEED)).isFalse();\n assertThat(loadControl.shouldContinueLoading(MAX_BUFFER_US - 1, SPEED)).isFalse();\n ass... | {
"fields": [
{
"declarator": "DEFAULT_MIN_BUFFER_MS = 15000",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MIN_BUFFER_MS = 15000;",
"type": "int",
"var_name": "DEFAULT_MIN_BUFFER_MS"
},
{
"declarator": "DEFAULT_MAX_BUFFER_MS = ... | {
"body": "@Override\n public boolean shouldContinueLoading(long bufferedDurationUs, float playbackSpeed) {\n boolean targetBufferSizeReached = allocator.getTotalBytesAllocated() >= targetBufferSize;\n long minBufferUs = hasVideo ? minBufferVideoUs : minBufferAudioUs;\n if (playbackSpeed > 1) {\n // Th... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_503 | {
"fields": [
{
"declarator": "THREE_EMPTY_MEDIA_CHUNK_ITERATORS =\n new MediaChunkIterator[] {\n MediaChunkIterator.EMPTY, MediaChunkIterator.EMPTY, MediaChunkIterator.EMPTY\n }",
"modifier": "private static final",
"original_string": "private static final MediaChunkIterator[] ... | {
"body": "@Test\n public void testEvaluateQueueSizeDoNotReevaluateUntilAfterMinTimeBetweenBufferReevaluation() {\n Format format1 = videoFormat(/* bitrate= */ 500, /* width= */ 320, /* height= */ 240);\n Format format2 = videoFormat(/* bitrate= */ 1000, /* width= */ 640, /* height= */ 480);\n Format format... | {
"fields": [
{
"declarator": "DEFAULT_MIN_DURATION_FOR_QUALITY_INCREASE_MS = 10000",
"modifier": "public static final",
"original_string": "public static final int DEFAULT_MIN_DURATION_FOR_QUALITY_INCREASE_MS = 10000;",
"type": "int",
"var_name": "DEFAULT_MIN_DURATION_FOR_QUALITY_IN... | {
"body": "@Override\n public int evaluateQueueSize(long playbackPositionUs, List<? extends MediaChunk> queue) {\n long nowMs = clock.elapsedRealtime();\n if (!shouldEvaluateQueueSize(nowMs)) {\n return queue.size();\n }\n\n lastBufferEvaluationMs = nowMs;\n if (queue.isEmpty()) {\n return 0... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_0 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/extractor/ogg/VorbisUtilTest.java",
"identifier": "VorbisUtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testILog() throws Exception {\n assertThat(iLog(0)).isEqualTo(0);\n assertThat(iLog(1)).isEqualTo(1);\n assertThat(iLog(2)).isEqualTo(2);\n assertThat(iLog(3)).isEqualTo(2);\n assertThat(iLog(4)).isEqualTo(3);\n assertThat(iLog(5)).isEqualTo(3);\n assertThat(iLog(8... | {
"fields": [
{
"declarator": "TAG = \"VorbisUtil\"",
"modifier": "private static final",
"original_string": "private static final String TAG = \"VorbisUtil\";",
"type": "String",
"var_name": "TAG"
}
],
"file": "videoplayer-core/src/main/java/com/google/android/exoplayer2/ext... | {
"body": "public static int iLog(int x) {\n int val = 0;\n while (x > 0) {\n val++;\n x >>>= 1;\n }\n return val;\n }",
"class_method_signature": "VorbisUtil.iLog(int x)",
"constructor": false,
"full_signature": "public static int iLog(int x)",
"identifier": "iLog",
"invocations": []... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_446 | {
"fields": [
{
"declarator": "DATA_1 = new SchemeData(WIDEVINE_UUID, VIDEO_MP4,\n TestUtil.buildTestData(128, 1 /* data seed */))",
"modifier": "private static final",
"original_string": "private static final SchemeData DATA_1 = new SchemeData(WIDEVINE_UUID, VIDEO_MP4,\n TestUtil.buil... | {
"body": "@Test\n @SuppressWarnings(\"deprecation\")\n public void testSchemeDatasWithSameUuid() {\n DrmInitData testInitData = new DrmInitData(DATA_1, DATA_1B);\n assertThat(testInitData.schemeDataCount).isEqualTo(2);\n // Deprecated get method should return first entry.\n assertThat(testInitData.get(... | {
"fields": [
{
"declarator": "schemeDatas",
"modifier": "private final",
"original_string": "private final SchemeData[] schemeDatas;",
"type": "SchemeData[]",
"var_name": "schemeDatas"
},
{
"declarator": "hashCode",
"modifier": "private",
"original_string":... | {
"body": "@Deprecated\n public @Nullable SchemeData get(UUID uuid) {\n for (SchemeData schemeData : schemeDatas) {\n if (schemeData.matches(uuid)) {\n return schemeData;\n }\n }\n return null;\n }",
"class_method_signature": "DrmInitData.get(UUID uuid)",
"constructor": false,
"full_... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_368 | {
"fields": [
{
"declarator": "window",
"modifier": "private",
"original_string": "private Window window;",
"type": "Window",
"var_name": "window"
},
{
"declarator": "period",
"modifier": "private",
"original_string": "private Period period;",
"type": ... | {
"body": "@Test\n public void testGetPeriodPositionDynamicWindowUnknownDuration() {\n SinglePeriodTimeline timeline = new SinglePeriodTimeline(C.TIME_UNSET, false, true);\n // Should return null with any positive position projection.\n Pair<Object, Long> position = timeline.getPeriodPosition(window, period... | {
"fields": [
{
"declarator": "UID = new Object()",
"modifier": "private static final",
"original_string": "private static final Object UID = new Object();",
"type": "Object",
"var_name": "UID"
},
{
"declarator": "presentationStartTimeMs",
"modifier": "private fin... | {
"body": "@Override\n public Object getUidOfPeriod(int periodIndex) {\n Assertions.checkIndex(periodIndex, 0, 1);\n return UID;\n }",
"class_method_signature": "SinglePeriodTimeline.getUidOfPeriod(int periodIndex)",
"constructor": false,
"full_signature": "@Override public Object getUidOfPeriod(int per... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_80 | {
"fields": [
{
"declarator": "TEST_DATA = new byte[] {0x3C, (byte) 0xD2, (byte) 0x5F, (byte) 0x01,\n (byte) 0xFF, (byte) 0x14, (byte) 0x60, (byte) 0x99}",
"modifier": "private static final",
"original_string": "private static final byte[] TEST_DATA = new byte[] {0x3C, (byte) 0xD2, (byte) 0... | {
"body": "@Test\n public void testReadBit() {\n assertReadBitsToEnd(0);\n }",
"class_method_signature": "ParsableBitArrayTest.testReadBit()",
"constructor": false,
"full_signature": "@Test public void testReadBit()",
"identifier": "testReadBit",
"invocations": [
"assertReadBitsToEnd"
],
"modif... | {
"fields": [
{
"declarator": "data",
"modifier": "public",
"original_string": "public byte[] data;",
"type": "byte[]",
"var_name": "data"
},
{
"declarator": "byteOffset",
"modifier": "private",
"original_string": "private int byteOffset;",
"type": "in... | {
"body": "public boolean readBit() {\n boolean returnValue = (data[byteOffset] & (0x80 >> bitOffset)) != 0;\n skipBit();\n return returnValue;\n }",
"class_method_signature": "ParsableBitArray.readBit()",
"constructor": false,
"full_signature": "public boolean readBit()",
"identifier": "readBit",
... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_387 | {
"fields": [
{
"declarator": "TEST_AD_GROUP_TMES_US = new long[] {0, C.msToUs(10_000)}",
"modifier": "private static final",
"original_string": "private static final long[] TEST_AD_GROUP_TMES_US = new long[] {0, C.msToUs(10_000)};",
"type": "long[]",
"var_name": "TEST_AD_GROUP_TMES_... | {
"body": "@Test\n public void testSetAdCount() {\n assertThat(state.adGroups[0].count).isEqualTo(C.LENGTH_UNSET);\n state = state.withAdCount(/* adGroupIndex= */ 0, /* adCount= */ 1);\n assertThat(state.adGroups[0].count).isEqualTo(1);\n }",
"class_method_signature": "AdPlaybackStateTest.testSetAdCount(... | {
"fields": [
{
"declarator": "AD_STATE_UNAVAILABLE = 0",
"modifier": "public static final",
"original_string": "public static final int AD_STATE_UNAVAILABLE = 0;",
"type": "int",
"var_name": "AD_STATE_UNAVAILABLE"
},
{
"declarator": "AD_STATE_AVAILABLE = 1",
"mod... | {
"body": "@CheckResult\n public AdPlaybackState withAdCount(int adGroupIndex, int adCount) {\n Assertions.checkArgument(adCount > 0);\n if (adGroups[adGroupIndex].count == adCount) {\n return this;\n }\n AdGroup[] adGroups = Arrays.copyOf(this.adGroups, this.adGroups.length);\n adGroups[adGroupI... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_104 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/util/UriUtilTest.java",
"identifier": "UriUtilTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testResolveAbnormal() {\n String base = \"http://a/b/c/d;p?q\";\n\n assertThat(resolve(base, \"../../../g\")).isEqualTo(\"http://a/g\");\n assertThat(resolve(base, \"../../../../g\")).isEqualTo(\"http://a/g\");\n\n assertThat(resolve(base, \"/./g\")).isEqualTo(\"http://a/g\... | {
"fields": [
{
"declarator": "INDEX_COUNT = 4",
"modifier": "private static final",
"original_string": "private static final int INDEX_COUNT = 4;",
"type": "int",
"var_name": "INDEX_COUNT"
},
{
"declarator": "SCHEME_COLON = 0",
"modifier": "private static final",... | {
"body": "public static String resolve(String baseUri, String referenceUri) {\n StringBuilder uri = new StringBuilder();\n\n // Map null onto empty string, to make the following logic simpler.\n baseUri = baseUri == null ? \"\" : baseUri;\n referenceUri = referenceUri == null ? \"\" : referenceUri;\n\n ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_411 | {
"fields": [
{
"declarator": "EMPTY_NAME = \"\"",
"modifier": "private static final",
"original_string": "private static final String EMPTY_NAME = \"\";",
"type": "String",
"var_name": "EMPTY_NAME"
},
{
"declarator": "databaseProvider",
"modifier": "private",
... | {
"body": "@Test\n public void getDownload_nonExistingId_returnsNull() throws DatabaseIOException {\n assertThat(downloadIndex.getDownload(\"non existing id\")).isNull();\n }",
"class_method_signature": "DefaultDownloadIndexTest.getDownload_nonExistingId_returnsNull()",
"constructor": false,
"full_signatur... | {
"fields": [
{
"declarator": "TABLE_PREFIX = DatabaseProvider.TABLE_PREFIX + \"Downloads\"",
"modifier": "private static final",
"original_string": "private static final String TABLE_PREFIX = DatabaseProvider.TABLE_PREFIX + \"Downloads\";",
"type": "String",
"var_name": "TABLE_PREFI... | {
"body": "@Override\n @Nullable\n public Download getDownload(String id) throws DatabaseIOException {\n ensureInitialized();\n try (Cursor cursor = getCursor(WHERE_ID_EQUALS, new String[] {id})) {\n if (cursor.getCount() == 0) {\n return null;\n }\n cursor.moveToNext();\n return ge... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_313 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void initialBitrateEstimateOverwrite_for3G_whileConnectedTo3G_setsInitialEstimate() {\n setActiveNetworkInfo(networkInfo3g);\n DefaultBandwidthMeter bandwidthMeter =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext())\n .setInitialBitrate... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_190 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/text/webvtt/WebvttCueParserTest.java",
"identifier": "WebvttCueParserTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParseMalformedNestedElements() throws Exception {\n Spanned text = parseCueText(\"<b><u>An unclosed u tag with <i>italic</u> inside</i></b>\");\n assertThat(text.toString()).isEqualTo(\"An unclosed u tag with italic inside\");\n\n UnderlineSpan[] underlineSpans = getSpans(... | {
"fields": [
{
"declarator": "CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\")",
"modifier": "public static final",
"original_string": "public static final Pattern CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\");",... | {
"body": "static void parseCueText(String id, String markup, WebvttCue.Builder builder,\n List<WebvttCssStyle> styles) {\n SpannableStringBuilder spannedText = new SpannableStringBuilder();\n ArrayDeque<StartTag> startTagStack = new ArrayDeque<>();\n List<StyleMatch> scratchStyleMatches = new ArrayList... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_485 | {
"fields": [
{
"declarator": "ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_AUDIO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n ... | {
"body": "@Test\n public void testSelectTracksPreferTrackWithinCapabilities() throws Exception {\n Format supportedFormat = buildAudioFormat(\"supportedFormat\");\n Format exceededFormat = buildAudioFormat(\"exceededFormat\");\n TrackGroupArray trackGroups = wrapFormats(exceededFormat, supportedFormat);\n\... | {
"fields": [
{
"declarator": "FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f",
"modifier": "private static final",
"original_string": "private static final float FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f;",
"type": "float",
"var_name": "FRACTION_TO_CONSIDER_FULLSCREEN"
},
{
"de... | {
"body": "@Override\n protected final Pair<@NullableType RendererConfiguration[], @NullableType TrackSelection[]>\n selectTracks(\n MappedTrackInfo mappedTrackInfo,\n int[][][] rendererFormatSupports,\n int[] rendererMixedMimeTypeAdaptationSupports)\n throws ExoPlaybackExcep... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_201 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/text/webvtt/WebvttCueParserTest.java",
"identifier": "WebvttCueParserTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParseMonkey() throws Exception {\n Spanned text = parseCueText(\"< u>An unclosed u tag with <<<<< i>italic</u></u></u></u >\"\n + \"</i><u><u> inside\");\n assertThat(text.toString()).isEqualTo(\"An unclosed u tag with italic inside\");\n text = parseCueText(\">>... | {
"fields": [
{
"declarator": "CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\")",
"modifier": "public static final",
"original_string": "public static final Pattern CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\");",... | {
"body": "static void parseCueText(String id, String markup, WebvttCue.Builder builder,\n List<WebvttCssStyle> styles) {\n SpannableStringBuilder spannedText = new SpannableStringBuilder();\n ArrayDeque<StartTag> startTagStack = new ArrayDeque<>();\n List<StyleMatch> scratchStyleMatches = new ArrayList... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_344 | {
"fields": [
{
"declarator": "mediaSource",
"modifier": "private",
"original_string": "private ConcatenatingMediaSource mediaSource;",
"type": "ConcatenatingMediaSource",
"var_name": "mediaSource"
},
{
"declarator": "testRunner",
"modifier": "private",
"ori... | {
"body": "@Test\n public void testCustomCallbackBeforePreparationAddMultipleWithIndex() {\n ConditionVariable runnableInvoked = new ConditionVariable();\n\n DummyMainThread dummyMainThread = new DummyMainThread();\n dummyMainThread.runOnMainThread(\n () ->\n mediaSource.addMediaSources(\n... | {
"fields": [
{
"declarator": "MSG_ADD = 0",
"modifier": "private static final",
"original_string": "private static final int MSG_ADD = 0;",
"type": "int",
"var_name": "MSG_ADD"
},
{
"declarator": "MSG_REMOVE = 1",
"modifier": "private static final",
"origin... | {
"body": "public final synchronized void addMediaSources(Collection<MediaSource> mediaSources) {\n addPublicMediaSources(\n mediaSourcesPublic.size(),\n mediaSources,\n /* handler= */ null,\n /* onCompletionAction= */ null);\n }",
"class_method_signature": "ConcatenatingMediaSource.... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_217 | {
"fields": [
{
"declarator": "NO_SUBTITLE = \"tx3g/no_subtitle\"",
"modifier": "private static final",
"original_string": "private static final String NO_SUBTITLE = \"tx3g/no_subtitle\";",
"type": "String",
"var_name": "NO_SUBTITLE"
},
{
"declarator": "SAMPLE_JUST_TEXT... | {
"body": "@Test\n public void testInitializationAllDefaultsDecodeWithStyl()\n throws IOException, SubtitleDecoderException {\n byte[] initBytes =\n TestUtil.getByteArray(\n ApplicationProvider.getApplicationContext(), INITIALIZATION_ALL_DEFAULTS);\n Tx3gDecoder decoder = new Tx3gDecoder... | {
"fields": [
{
"declarator": "BOM_UTF16_BE = '\\uFEFF'",
"modifier": "private static final",
"original_string": "private static final char BOM_UTF16_BE = '\\uFEFF';",
"type": "char",
"var_name": "BOM_UTF16_BE"
},
{
"declarator": "BOM_UTF16_LE = '\\uFFFE'",
"modif... | {
"body": "@Override\n protected Subtitle decode(byte[] bytes, int length, boolean reset)\n throws SubtitleDecoderException {\n parsableByteArray.reset(bytes, length);\n String cueTextString = readSubtitleText(parsableByteArray);\n if (cueTextString.isEmpty()) {\n return Tx3gSubtitle.EMPTY;\n }... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_352 | {
"fields": [
{
"declarator": "mediaSource",
"modifier": "private",
"original_string": "private ConcatenatingMediaSource mediaSource;",
"type": "ConcatenatingMediaSource",
"var_name": "mediaSource"
},
{
"declarator": "testRunner",
"modifier": "private",
"ori... | {
"body": "@Test\n public void testClear() throws IOException {\n DummyMainThread dummyMainThread = new DummyMainThread();\n final FakeMediaSource preparedChildSource = createFakeMediaSource();\n final FakeMediaSource unpreparedChildSource =\n new FakeMediaSource(/* timeline= */ null, /* manifest= */... | {
"fields": [
{
"declarator": "MSG_ADD = 0",
"modifier": "private static final",
"original_string": "private static final int MSG_ADD = 0;",
"type": "int",
"var_name": "MSG_ADD"
},
{
"declarator": "MSG_REMOVE = 1",
"modifier": "private static final",
"origin... | {
"body": "public final synchronized void clear() {\n removeMediaSourceRange(0, getSize());\n }",
"class_method_signature": "ConcatenatingMediaSource.clear()",
"constructor": false,
"full_signature": "public final synchronized void clear()",
"identifier": "clear",
"invocations": [
"removeMediaSource... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_55 | {
"fields": [
{
"declarator": "packetPayload",
"modifier": "private",
"original_string": "private byte[] packetPayload;",
"type": "byte[]",
"var_name": "packetPayload"
},
{
"declarator": "payloadReader",
"modifier": "private",
"original_string": "private Cus... | {
"body": "@Test\n public void testSingleOnePacketSection() {\n packetPayload[0] = 3;\n insertTableSection(4, (byte) 99, 3);\n reader.consume(new ParsableByteArray(packetPayload), FLAG_PAYLOAD_UNIT_START_INDICATOR);\n assertThat(payloadReader.parsedTableIds).isEqualTo(singletonList(99));\n }",
"class_... | {
"fields": [
{
"declarator": "SECTION_HEADER_LENGTH = 3",
"modifier": "private static final",
"original_string": "private static final int SECTION_HEADER_LENGTH = 3;",
"type": "int",
"var_name": "SECTION_HEADER_LENGTH"
},
{
"declarator": "DEFAULT_SECTION_BUFFER_LENGTH ... | {
"body": "@Override\n public void consume(ParsableByteArray data, @Flags int flags) {\n boolean payloadUnitStartIndicator = (flags & FLAG_PAYLOAD_UNIT_START_INDICATOR) != 0;\n int payloadStartPosition = C.POSITION_UNSET;\n if (payloadUnitStartIndicator) {\n int payloadStartOffset = data.readUnsignedBy... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_305 | {
"fields": [
{
"declarator": "SIMULATED_TRANSFER_COUNT = 100",
"modifier": "private static final",
"original_string": "private static final int SIMULATED_TRANSFER_COUNT = 100;",
"type": "int",
"var_name": "SIMULATED_TRANSFER_COUNT"
},
{
"declarator": "FAST_COUNTRY_ISO ... | {
"body": "@Test\n public void initialBitrateEstimateOverwrite_whileConnectedToNetwork_setsInitialEstimate() {\n setActiveNetworkInfo(networkInfoWifi);\n DefaultBandwidthMeter bandwidthMeter =\n new DefaultBandwidthMeter.Builder(ApplicationProvider.getApplicationContext())\n .setInitialBitrat... | {
"fields": [
{
"declarator": "DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryGroupAssignment()",
"modifier": "public static final",
"original_string": "public static final Map<String, int[]> DEFAULT_INITIAL_BITRATE_COUNTRY_GROUPS =\n createInitialBitrateCountryG... | {
"body": "@Override\n public synchronized long getBitrateEstimate() {\n return bitrateEstimate;\n }",
"class_method_signature": "DefaultBandwidthMeter.getBitrateEstimate()",
"constructor": false,
"full_signature": "@Override public synchronized long getBitrateEstimate()",
"identifier": "getBitrateEstima... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_186 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/text/webvtt/WebvttCueParserTest.java",
"identifier": "WebvttCueParserTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParseStrictValidClassesAndTrailingTokens() throws Exception {\n Spanned text = parseCueText(\"<v.first.loud Esme>\"\n + \"This <u.style1.style2 some stuff>is</u> text with <b.foo><i.bar>html</i></b> tags\");\n\n assertThat(text.toString()).isEqualTo(\"This is text with... | {
"fields": [
{
"declarator": "CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\")",
"modifier": "public static final",
"original_string": "public static final Pattern CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\");",... | {
"body": "static void parseCueText(String id, String markup, WebvttCue.Builder builder,\n List<WebvttCssStyle> styles) {\n SpannableStringBuilder spannedText = new SpannableStringBuilder();\n ArrayDeque<StartTag> startTagStack = new ArrayDeque<>();\n List<StyleMatch> scratchStyleMatches = new ArrayList... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_493 | {
"fields": [
{
"declarator": "ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n new FakeRendererCapabilities(C.TRACK_TYPE_AUDIO)",
"modifier": "private static final",
"original_string": "private static final RendererCapabilities ALL_AUDIO_FORMAT_SUPPORTED_RENDERER_CAPABILITIES =\n ... | {
"body": "@Test\n public void testSelectTracksExceedingCapabilitiesSelectLowerNumChannel()\n throws Exception {\n Format higherChannelFormat =\n Format.createAudioSampleFormat(\n \"audioFormat\",\n MimeTypes.AUDIO_AAC,\n null,\n Format.NO_VALUE,\n ... | {
"fields": [
{
"declarator": "FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f",
"modifier": "private static final",
"original_string": "private static final float FRACTION_TO_CONSIDER_FULLSCREEN = 0.98f;",
"type": "float",
"var_name": "FRACTION_TO_CONSIDER_FULLSCREEN"
},
{
"de... | {
"body": "@Override\n protected final Pair<@NullableType RendererConfiguration[], @NullableType TrackSelection[]>\n selectTracks(\n MappedTrackInfo mappedTrackInfo,\n int[][][] rendererFormatSupports,\n int[] rendererMixedMimeTypeAdaptationSupports)\n throws ExoPlaybackExcep... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_169 | {
"fields": [
{
"declarator": "EMPTY_FILE = \"subrip/empty\"",
"modifier": "private static final",
"original_string": "private static final String EMPTY_FILE = \"subrip/empty\";",
"type": "String",
"var_name": "EMPTY_FILE"
},
{
"declarator": "TYPICAL_FILE = \"subrip/typ... | {
"body": "@Test\n public void testDecodeTypicalMissingTimecode() throws IOException {\n // Parsing should succeed, parsing the first and third cues only.\n SubripDecoder decoder = new SubripDecoder();\n byte[] bytes =\n TestUtil.getByteArray(\n ApplicationProvider.getApplicationContext(),... | {
"fields": [
{
"declarator": "START_FRACTION = 0.08f",
"modifier": "static final",
"original_string": "static final float START_FRACTION = 0.08f;",
"type": "float",
"var_name": "START_FRACTION"
},
{
"declarator": "END_FRACTION = 1 - START_FRACTION",
"modifier": "... | {
"body": "@Override\n protected SubripSubtitle decode(byte[] bytes, int length, boolean reset) {\n ArrayList<Cue> cues = new ArrayList<>();\n LongArray cueTimesUs = new LongArray();\n ParsableByteArray subripData = new ParsableByteArray(bytes, length);\n String currentLine;\n\n while ((currentLine = ... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
133447770_187 | {
"fields": [],
"file": "videoplayer-core/src/test/java/com/google/android/exoplayer2/text/webvtt/WebvttCueParserTest.java",
"identifier": "WebvttCueParserTest",
"interfaces": "",
"superclass": ""
} | {
"body": "@Test\n public void testParseStrictValidUnsupportedTagsStrippedOut() throws Exception {\n Spanned text = parseCueText(\"<v.first.loud Esme>This <unsupported>is</unsupported> text with \"\n + \"<notsupp><invalid>html</invalid></notsupp> tags\");\n assertThat(text.toString()).isEqualTo(\"This i... | {
"fields": [
{
"declarator": "CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\")",
"modifier": "public static final",
"original_string": "public static final Pattern CUE_HEADER_PATTERN = Pattern\n .compile(\"^(\\\\S+)\\\\s+-->\\\\s+(\\\\S+)(.*)?$\");",... | {
"body": "static void parseCueText(String id, String markup, WebvttCue.Builder builder,\n List<WebvttCssStyle> styles) {\n SpannableStringBuilder spannedText = new SpannableStringBuilder();\n ArrayDeque<StartTag> startTagStack = new ArrayDeque<>();\n List<StyleMatch> scratchStyleMatches = new ArrayList... | {
"created": null,
"fork": null,
"fork_count": 4,
"is_fork": false,
"language": "Java",
"license": "licensed",
"repo_id": 133447770,
"size": 39077,
"stargazer_count": 20,
"stars": null,
"updates": null,
"url": "https://github.com/ybj366533/YY-VideoPlayer"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.