id
int32
0
165k
repo
stringlengths
7
58
path
stringlengths
12
218
func_name
stringlengths
3
140
original_string
stringlengths
73
34.1k
language
stringclasses
1 value
code
stringlengths
73
34.1k
code_tokens
list
docstring
stringlengths
3
16k
docstring_tokens
list
sha
stringlengths
40
40
url
stringlengths
105
339
16,300
SonarSource/sonarqube
server/sonar-main/src/main/java/org/sonar/application/command/EsJvmOptions.java
EsJvmOptions.mandatoryOptions
private static Map<String, String> mandatoryOptions(System2 system2, EsInstallation esInstallation) { Map<String, String> res = new LinkedHashMap<>(16); // GC configuration res.put("-XX:+UseConcMarkSweepGC", ""); res.put("-XX:CMSInitiatingOccupancyFraction=", "75"); res.put("-XX:+UseCMSInitiatingOcc...
java
private static Map<String, String> mandatoryOptions(System2 system2, EsInstallation esInstallation) { Map<String, String> res = new LinkedHashMap<>(16); // GC configuration res.put("-XX:+UseConcMarkSweepGC", ""); res.put("-XX:CMSInitiatingOccupancyFraction=", "75"); res.put("-XX:+UseCMSInitiatingOcc...
[ "private", "static", "Map", "<", "String", ",", "String", ">", "mandatoryOptions", "(", "System2", "system2", ",", "EsInstallation", "esInstallation", ")", "{", "Map", "<", "String", ",", "String", ">", "res", "=", "new", "LinkedHashMap", "<>", "(", "16", ...
with some changes to fit running bundled in SQ
[ "with", "some", "changes", "to", "fit", "running", "bundled", "in", "SQ" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-main/src/main/java/org/sonar/application/command/EsJvmOptions.java#L49-L130
16,301
SonarSource/sonarqube
sonar-core/src/main/java/org/sonar/core/util/CloseableIterator.java
CloseableIterator.close
@Override public final void close() { try { doClose(); isClosed = true; } catch (Exception e) { Throwables.propagate(e); } }
java
@Override public final void close() { try { doClose(); isClosed = true; } catch (Exception e) { Throwables.propagate(e); } }
[ "@", "Override", "public", "final", "void", "close", "(", ")", "{", "try", "{", "doClose", "(", ")", ";", "isClosed", "=", "true", ";", "}", "catch", "(", "Exception", "e", ")", "{", "Throwables", ".", "propagate", "(", "e", ")", ";", "}", "}" ]
Do not declare "throws IOException"
[ "Do", "not", "declare", "throws", "IOException" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-core/src/main/java/org/sonar/core/util/CloseableIterator.java#L141-L149
16,302
SonarSource/sonarqube
sonar-duplications/src/main/java/org/sonar/duplications/detector/original/BlocksGroup.java
BlocksGroup.first
@CheckForNull public Block first(String resourceId) { for (Block block : blocks) { if (resourceId.equals(block.getResourceId())) { return block; } } return null; }
java
@CheckForNull public Block first(String resourceId) { for (Block block : blocks) { if (resourceId.equals(block.getResourceId())) { return block; } } return null; }
[ "@", "CheckForNull", "public", "Block", "first", "(", "String", "resourceId", ")", "{", "for", "(", "Block", "block", ":", "blocks", ")", "{", "if", "(", "resourceId", ".", "equals", "(", "block", ".", "getResourceId", "(", ")", ")", ")", "{", "return"...
First block from this group with specified resource id.
[ "First", "block", "from", "this", "group", "with", "specified", "resource", "id", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-duplications/src/main/java/org/sonar/duplications/detector/original/BlocksGroup.java#L76-L84
16,303
SonarSource/sonarqube
sonar-duplications/src/main/java/org/sonar/duplications/detector/original/BlocksGroup.java
BlocksGroup.intersect
private static BlocksGroup intersect(BlocksGroup group1, BlocksGroup group2) { BlocksGroup intersection = new BlocksGroup(); List<Block> list1 = group1.blocks; List<Block> list2 = group2.blocks; int i = 0; int j = 0; while (i < list1.size() && j < list2.size()) { Block block1 = list1.get(i...
java
private static BlocksGroup intersect(BlocksGroup group1, BlocksGroup group2) { BlocksGroup intersection = new BlocksGroup(); List<Block> list1 = group1.blocks; List<Block> list2 = group2.blocks; int i = 0; int j = 0; while (i < list1.size() && j < list2.size()) { Block block1 = list1.get(i...
[ "private", "static", "BlocksGroup", "intersect", "(", "BlocksGroup", "group1", ",", "BlocksGroup", "group2", ")", "{", "BlocksGroup", "intersection", "=", "new", "BlocksGroup", "(", ")", ";", "List", "<", "Block", ">", "list1", "=", "group1", ".", "blocks", ...
Intersection of two groups is a group, which contains blocks from second group that have corresponding block from first group with same resource id and with corrected index.
[ "Intersection", "of", "two", "groups", "is", "a", "group", "which", "contains", "blocks", "from", "second", "group", "that", "have", "corresponding", "block", "from", "first", "group", "with", "same", "resource", "id", "and", "with", "corrected", "index", "." ...
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-duplications/src/main/java/org/sonar/duplications/detector/original/BlocksGroup.java#L95-L132
16,304
SonarSource/sonarqube
sonar-duplications/src/main/java/org/sonar/duplications/detector/original/BlocksGroup.java
BlocksGroup.subsumedBy
private static boolean subsumedBy(BlocksGroup group1, BlocksGroup group2, int indexCorrection) { List<Block> list1 = group1.blocks; List<Block> list2 = group2.blocks; int i = 0; int j = 0; while (i < list1.size() && j < list2.size()) { Block block1 = list1.get(i); Block block2 = list2.ge...
java
private static boolean subsumedBy(BlocksGroup group1, BlocksGroup group2, int indexCorrection) { List<Block> list1 = group1.blocks; List<Block> list2 = group2.blocks; int i = 0; int j = 0; while (i < list1.size() && j < list2.size()) { Block block1 = list1.get(i); Block block2 = list2.ge...
[ "private", "static", "boolean", "subsumedBy", "(", "BlocksGroup", "group1", ",", "BlocksGroup", "group2", ",", "int", "indexCorrection", ")", "{", "List", "<", "Block", ">", "list1", "=", "group1", ".", "blocks", ";", "List", "<", "Block", ">", "list2", "=...
One group is subsumed by another group, when each block from first group has corresponding block from second group with same resource id and with corrected index.
[ "One", "group", "is", "subsumed", "by", "another", "group", "when", "each", "block", "from", "first", "group", "has", "corresponding", "block", "from", "second", "group", "with", "same", "resource", "id", "and", "with", "corrected", "index", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-duplications/src/main/java/org/sonar/duplications/detector/original/BlocksGroup.java#L138-L167
16,305
SonarSource/sonarqube
server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/issue/AdHocRuleCreator.java
AdHocRuleCreator.persistAndIndex
public RuleDto persistAndIndex(DbSession dbSession, NewAdHocRule adHoc, OrganizationDto organizationDto) { RuleDao dao = dbClient.ruleDao(); Optional<RuleDto> existingRuleDtoOpt = dao.selectByKey(dbSession, organizationDto, adHoc.getKey()); RuleMetadataDto metadata; long now = system2.now(); if (!ex...
java
public RuleDto persistAndIndex(DbSession dbSession, NewAdHocRule adHoc, OrganizationDto organizationDto) { RuleDao dao = dbClient.ruleDao(); Optional<RuleDto> existingRuleDtoOpt = dao.selectByKey(dbSession, organizationDto, adHoc.getKey()); RuleMetadataDto metadata; long now = system2.now(); if (!ex...
[ "public", "RuleDto", "persistAndIndex", "(", "DbSession", "dbSession", ",", "NewAdHocRule", "adHoc", ",", "OrganizationDto", "organizationDto", ")", "{", "RuleDao", "dao", "=", "dbClient", ".", "ruleDao", "(", ")", ";", "Optional", "<", "RuleDto", ">", "existing...
Persists a new add hoc rule in the DB and indexes it. @return the rule that was inserted in the DB, which <b>includes the generated ID</b>.
[ "Persists", "a", "new", "add", "hoc", "rule", "in", "the", "DB", "and", "indexes", "it", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/issue/AdHocRuleCreator.java#L59-L115
16,306
SonarSource/sonarqube
server/sonar-process/src/main/java/org/sonar/process/AesCipher.java
AesCipher.hasSecretKey
boolean hasSecretKey() { String path = getPathToSecretKey(); if (StringUtils.isNotBlank(path)) { File file = new File(path); return file.exists() && file.isFile(); } return false; }
java
boolean hasSecretKey() { String path = getPathToSecretKey(); if (StringUtils.isNotBlank(path)) { File file = new File(path); return file.exists() && file.isFile(); } return false; }
[ "boolean", "hasSecretKey", "(", ")", "{", "String", "path", "=", "getPathToSecretKey", "(", ")", ";", "if", "(", "StringUtils", ".", "isNotBlank", "(", "path", ")", ")", "{", "File", "file", "=", "new", "File", "(", "path", ")", ";", "return", "file", ...
This method checks the existence of the file, but not the validity of the contained key.
[ "This", "method", "checks", "the", "existence", "of", "the", "file", "but", "not", "the", "validity", "of", "the", "contained", "key", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-process/src/main/java/org/sonar/process/AesCipher.java#L86-L93
16,307
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/MyBatis.java
MyBatis.newScrollingSelectStatement
public PreparedStatement newScrollingSelectStatement(DbSession session, String sql) { int fetchSize = database.getDialect().getScrollDefaultFetchSize(); return newScrollingSelectStatement(session, sql, fetchSize); }
java
public PreparedStatement newScrollingSelectStatement(DbSession session, String sql) { int fetchSize = database.getDialect().getScrollDefaultFetchSize(); return newScrollingSelectStatement(session, sql, fetchSize); }
[ "public", "PreparedStatement", "newScrollingSelectStatement", "(", "DbSession", "session", ",", "String", "sql", ")", "{", "int", "fetchSize", "=", "database", ".", "getDialect", "(", ")", ".", "getScrollDefaultFetchSize", "(", ")", ";", "return", "newScrollingSelec...
Create a PreparedStatement for SELECT requests with scrolling of results
[ "Create", "a", "PreparedStatement", "for", "SELECT", "requests", "with", "scrolling", "of", "results" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/MyBatis.java#L312-L315
16,308
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/qualityprofile/QualityProfileDao.java
QualityProfileDao.selectDescendants
public Collection<QProfileDto> selectDescendants(DbSession dbSession, Collection<QProfileDto> profiles) { if (profiles.isEmpty()) { return emptyList(); } Collection<QProfileDto> children = selectChildren(dbSession, profiles); List<QProfileDto> descendants = new ArrayList<>(children); descendan...
java
public Collection<QProfileDto> selectDescendants(DbSession dbSession, Collection<QProfileDto> profiles) { if (profiles.isEmpty()) { return emptyList(); } Collection<QProfileDto> children = selectChildren(dbSession, profiles); List<QProfileDto> descendants = new ArrayList<>(children); descendan...
[ "public", "Collection", "<", "QProfileDto", ">", "selectDescendants", "(", "DbSession", "dbSession", ",", "Collection", "<", "QProfileDto", ">", "profiles", ")", "{", "if", "(", "profiles", ".", "isEmpty", "(", ")", ")", "{", "return", "emptyList", "(", ")",...
All descendants, in any order. The specified profiles are not included into results.
[ "All", "descendants", "in", "any", "order", ".", "The", "specified", "profiles", "are", "not", "included", "into", "results", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/qualityprofile/QualityProfileDao.java#L179-L187
16,309
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java
Rule.setParams
public Rule setParams(List<RuleParam> params) { this.params.clear(); for (RuleParam param : params) { param.setRule(this); this.params.add(param); } return this; }
java
public Rule setParams(List<RuleParam> params) { this.params.clear(); for (RuleParam param : params) { param.setRule(this); this.params.add(param); } return this; }
[ "public", "Rule", "setParams", "(", "List", "<", "RuleParam", ">", "params", ")", "{", "this", ".", "params", ".", "clear", "(", ")", ";", "for", "(", "RuleParam", "param", ":", "params", ")", "{", "param", ".", "setRule", "(", "this", ")", ";", "t...
Sets the rule parameters
[ "Sets", "the", "rule", "parameters" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java#L196-L203
16,310
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java
Rule.setTags
public Rule setTags(String[] tags) { this.tags = tags == null ? null : StringUtils.join(tags, ','); return this; }
java
public Rule setTags(String[] tags) { this.tags = tags == null ? null : StringUtils.join(tags, ','); return this; }
[ "public", "Rule", "setTags", "(", "String", "[", "]", "tags", ")", "{", "this", ".", "tags", "=", "tags", "==", "null", "?", "null", ":", "StringUtils", ".", "join", "(", "tags", ",", "'", "'", ")", ";", "return", "this", ";", "}" ]
For definition of rule only
[ "For", "definition", "of", "rule", "only" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/rules/Rule.java#L391-L394
16,311
SonarSource/sonarqube
sonar-core/src/main/java/org/sonar/core/issue/tracking/LineHashSequence.java
LineHashSequence.getHashForLine
public String getHashForLine(int line) { if (line > 0 && line <= hashes.size()) { return Strings.nullToEmpty(hashes.get(line - 1)); } return ""; }
java
public String getHashForLine(int line) { if (line > 0 && line <= hashes.size()) { return Strings.nullToEmpty(hashes.get(line - 1)); } return ""; }
[ "public", "String", "getHashForLine", "(", "int", "line", ")", "{", "if", "(", "line", ">", "0", "&&", "line", "<=", "hashes", ".", "size", "(", ")", ")", "{", "return", "Strings", ".", "nullToEmpty", "(", "hashes", ".", "get", "(", "line", "-", "1...
Hash of the given line, which starts with 1. Return empty string is the line does not exist.
[ "Hash", "of", "the", "given", "line", "which", "starts", "with", "1", ".", "Return", "empty", "string", "is", "the", "line", "does", "not", "exist", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-core/src/main/java/org/sonar/core/issue/tracking/LineHashSequence.java#L79-L84
16,312
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/batch/fs/internal/DefaultInputFile.java
DefaultInputFile.newRange
public TextRange newRange(int startOffset, int endOffset) { checkMetadata(); return newRangeValidPointers(newPointer(startOffset), newPointer(endOffset), false); }
java
public TextRange newRange(int startOffset, int endOffset) { checkMetadata(); return newRangeValidPointers(newPointer(startOffset), newPointer(endOffset), false); }
[ "public", "TextRange", "newRange", "(", "int", "startOffset", ",", "int", "endOffset", ")", "{", "checkMetadata", "(", ")", ";", "return", "newRangeValidPointers", "(", "newPointer", "(", "startOffset", ")", ",", "newPointer", "(", "endOffset", ")", ",", "fals...
Create Range from global offsets. Used for backward compatibility with older API.
[ "Create", "Range", "from", "global", "offsets", ".", "Used", "for", "backward", "compatibility", "with", "older", "API", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/batch/fs/internal/DefaultInputFile.java#L309-L312
16,313
SonarSource/sonarqube
sonar-scanner-engine/src/main/java/org/sonar/scanner/repository/language/DefaultLanguagesRepository.java
DefaultLanguagesRepository.get
@Override @CheckForNull public Language get(String languageKey) { org.sonar.api.resources.Language language = languages.get(languageKey); return language != null ? new Language(language.getKey(), language.getName(), language.getFileSuffixes()) : null; }
java
@Override @CheckForNull public Language get(String languageKey) { org.sonar.api.resources.Language language = languages.get(languageKey); return language != null ? new Language(language.getKey(), language.getName(), language.getFileSuffixes()) : null; }
[ "@", "Override", "@", "CheckForNull", "public", "Language", "get", "(", "String", "languageKey", ")", "{", "org", ".", "sonar", ".", "api", ".", "resources", ".", "Language", "language", "=", "languages", ".", "get", "(", "languageKey", ")", ";", "return",...
Get language.
[ "Get", "language", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-scanner-engine/src/main/java/org/sonar/scanner/repository/language/DefaultLanguagesRepository.java#L54-L59
16,314
SonarSource/sonarqube
sonar-scanner-engine/src/main/java/org/sonar/scanner/repository/language/DefaultLanguagesRepository.java
DefaultLanguagesRepository.all
@Override public Collection<Language> all() { org.sonar.api.resources.Language[] all = languages.all(); Collection<Language> result = new ArrayList<>(all.length); for (org.sonar.api.resources.Language language : all) { result.add(new Language(language.getKey(), language.getName(), language.getFileSu...
java
@Override public Collection<Language> all() { org.sonar.api.resources.Language[] all = languages.all(); Collection<Language> result = new ArrayList<>(all.length); for (org.sonar.api.resources.Language language : all) { result.add(new Language(language.getKey(), language.getName(), language.getFileSu...
[ "@", "Override", "public", "Collection", "<", "Language", ">", "all", "(", ")", "{", "org", ".", "sonar", ".", "api", ".", "resources", ".", "Language", "[", "]", "all", "=", "languages", ".", "all", "(", ")", ";", "Collection", "<", "Language", ">",...
Get list of all supported languages.
[ "Get", "list", "of", "all", "supported", "languages", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-scanner-engine/src/main/java/org/sonar/scanner/repository/language/DefaultLanguagesRepository.java#L64-L72
16,315
SonarSource/sonarqube
server/sonar-server-common/src/main/java/org/sonar/server/notification/NotificationDispatcherMetadata.java
NotificationDispatcherMetadata.setProperty
public NotificationDispatcherMetadata setProperty(String key, String value) { properties.put(key, value); return this; }
java
public NotificationDispatcherMetadata setProperty(String key, String value) { properties.put(key, value); return this; }
[ "public", "NotificationDispatcherMetadata", "setProperty", "(", "String", "key", ",", "String", "value", ")", "{", "properties", ".", "put", "(", "key", ",", "value", ")", ";", "return", "this", ";", "}" ]
Sets a property on this metadata object.
[ "Sets", "a", "property", "on", "this", "metadata", "object", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server-common/src/main/java/org/sonar/server/notification/NotificationDispatcherMetadata.java#L62-L65
16,316
SonarSource/sonarqube
sonar-scanner-protocol/src/main/java/org/sonar/scanner/protocol/viewer/TextLineNumber.java
TextLineNumber.setBorderGap
public void setBorderGap(int borderGap) { this.borderGap = borderGap; Border inner = new EmptyBorder(0, borderGap, 0, borderGap); setBorder(new CompoundBorder(OUTER, inner)); lastDigits = 0; setPreferredWidth(); }
java
public void setBorderGap(int borderGap) { this.borderGap = borderGap; Border inner = new EmptyBorder(0, borderGap, 0, borderGap); setBorder(new CompoundBorder(OUTER, inner)); lastDigits = 0; setPreferredWidth(); }
[ "public", "void", "setBorderGap", "(", "int", "borderGap", ")", "{", "this", ".", "borderGap", "=", "borderGap", ";", "Border", "inner", "=", "new", "EmptyBorder", "(", "0", ",", "borderGap", ",", "0", ",", "borderGap", ")", ";", "setBorder", "(", "new",...
The border gap is used in calculating the left and right insets of the border. Default value is 5. @param borderGap the gap in pixels
[ "The", "border", "gap", "is", "used", "in", "calculating", "the", "left", "and", "right", "insets", "of", "the", "border", ".", "Default", "value", "is", "5", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-scanner-protocol/src/main/java/org/sonar/scanner/protocol/viewer/TextLineNumber.java#L157-L163
16,317
SonarSource/sonarqube
sonar-scanner-protocol/src/main/java/org/sonar/scanner/protocol/viewer/TextLineNumber.java
TextLineNumber.setPreferredWidth
private void setPreferredWidth() { Element root = component.getDocument().getDefaultRootElement(); int lines = root.getElementCount(); int digits = Math.max(String.valueOf(lines).length(), minimumDisplayDigits); // Update sizes when number of digits in the line number changes if (lastDigits != dig...
java
private void setPreferredWidth() { Element root = component.getDocument().getDefaultRootElement(); int lines = root.getElementCount(); int digits = Math.max(String.valueOf(lines).length(), minimumDisplayDigits); // Update sizes when number of digits in the line number changes if (lastDigits != dig...
[ "private", "void", "setPreferredWidth", "(", ")", "{", "Element", "root", "=", "component", ".", "getDocument", "(", ")", ".", "getDefaultRootElement", "(", ")", ";", "int", "lines", "=", "root", ".", "getElementCount", "(", ")", ";", "int", "digits", "=",...
Calculate the width needed to display the maximum line number
[ "Calculate", "the", "width", "needed", "to", "display", "the", "maximum", "line", "number" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-scanner-protocol/src/main/java/org/sonar/scanner/protocol/viewer/TextLineNumber.java#L229-L248
16,318
SonarSource/sonarqube
sonar-scanner-protocol/src/main/java/org/sonar/scanner/protocol/viewer/TextLineNumber.java
TextLineNumber.paintComponent
@Override public void paintComponent(Graphics g) { super.paintComponent(g); // Determine the width of the space available to draw the line number FontMetrics fontMetrics = component.getFontMetrics(component.getFont()); Insets insets = getInsets(); int availableWidth = getSize().width - insets.le...
java
@Override public void paintComponent(Graphics g) { super.paintComponent(g); // Determine the width of the space available to draw the line number FontMetrics fontMetrics = component.getFontMetrics(component.getFont()); Insets insets = getInsets(); int availableWidth = getSize().width - insets.le...
[ "@", "Override", "public", "void", "paintComponent", "(", "Graphics", "g", ")", "{", "super", ".", "paintComponent", "(", "g", ")", ";", "// Determine the width of the space available to draw the line number", "FontMetrics", "fontMetrics", "=", "component", ".", "getFon...
Draw the line numbers
[ "Draw", "the", "line", "numbers" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-scanner-protocol/src/main/java/org/sonar/scanner/protocol/viewer/TextLineNumber.java#L253-L292
16,319
SonarSource/sonarqube
server/sonar-server-common/src/main/java/org/sonar/server/notification/NotificationService.java
NotificationService.hasProjectSubscribersForTypes
public boolean hasProjectSubscribersForTypes(String projectUuid, Set<Class<? extends Notification>> notificationTypes) { Set<String> dispatcherKeys = handlers.stream() .filter(handler -> notificationTypes.stream().anyMatch(notificationType -> handler.getNotificationClass() == notificationType)) .map(Not...
java
public boolean hasProjectSubscribersForTypes(String projectUuid, Set<Class<? extends Notification>> notificationTypes) { Set<String> dispatcherKeys = handlers.stream() .filter(handler -> notificationTypes.stream().anyMatch(notificationType -> handler.getNotificationClass() == notificationType)) .map(Not...
[ "public", "boolean", "hasProjectSubscribersForTypes", "(", "String", "projectUuid", ",", "Set", "<", "Class", "<", "?", "extends", "Notification", ">", ">", "notificationTypes", ")", "{", "Set", "<", "String", ">", "dispatcherKeys", "=", "handlers", ".", "stream...
Returns true if at least one user is subscribed to at least one notification with given types. Subscription can be global or on the specific project.
[ "Returns", "true", "if", "at", "least", "one", "user", "is", "subscribed", "to", "at", "least", "one", "notification", "with", "given", "types", ".", "Subscription", "can", "be", "global", "or", "on", "the", "specific", "project", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server-common/src/main/java/org/sonar/server/notification/NotificationService.java#L157-L167
16,320
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/component/ComponentDto.java
ComponentDto.getKey
public String getKey() { List<String> split = BRANCH_OR_PULL_REQUEST_SPLITTER.splitToList(kee); return split.size() == 2 ? split.get(0) : kee; }
java
public String getKey() { List<String> split = BRANCH_OR_PULL_REQUEST_SPLITTER.splitToList(kee); return split.size() == 2 ? split.get(0) : kee; }
[ "public", "String", "getKey", "(", ")", "{", "List", "<", "String", ">", "split", "=", "BRANCH_OR_PULL_REQUEST_SPLITTER", ".", "splitToList", "(", "kee", ")", ";", "return", "split", ".", "size", "(", ")", "==", "2", "?", "split", ".", "get", "(", "0",...
The key to be displayed to user, doesn't contain information on branches
[ "The", "key", "to", "be", "displayed", "to", "user", "doesn", "t", "contain", "information", "on", "branches" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/component/ComponentDto.java#L225-L228
16,321
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/batch/fs/internal/FileMetadata.java
FileMetadata.readMetadata
public Metadata readMetadata(Reader reader) { LineCounter lineCounter = new LineCounter("fromString", StandardCharsets.UTF_16); FileHashComputer fileHashComputer = new FileHashComputer("fromString"); LineOffsetCounter lineOffsetCounter = new LineOffsetCounter(); CharHandler[] handlers = {lineCounter, fi...
java
public Metadata readMetadata(Reader reader) { LineCounter lineCounter = new LineCounter("fromString", StandardCharsets.UTF_16); FileHashComputer fileHashComputer = new FileHashComputer("fromString"); LineOffsetCounter lineOffsetCounter = new LineOffsetCounter(); CharHandler[] handlers = {lineCounter, fi...
[ "public", "Metadata", "readMetadata", "(", "Reader", "reader", ")", "{", "LineCounter", "lineCounter", "=", "new", "LineCounter", "(", "\"fromString\"", ",", "StandardCharsets", ".", "UTF_16", ")", ";", "FileHashComputer", "fileHashComputer", "=", "new", "FileHashCo...
For testing purpose
[ "For", "testing", "purpose" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/batch/fs/internal/FileMetadata.java#L75-L89
16,322
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/batch/fs/internal/FileMetadata.java
FileMetadata.computeLineHashesForIssueTracking
public static void computeLineHashesForIssueTracking(InputFile f, LineHashConsumer consumer) { try { readFile(f.inputStream(), f.charset(), f.absolutePath(), new CharHandler[] {new LineHashComputer(consumer, f.file())}); } catch (IOException e) { throw new IllegalStateException("Failed to compute li...
java
public static void computeLineHashesForIssueTracking(InputFile f, LineHashConsumer consumer) { try { readFile(f.inputStream(), f.charset(), f.absolutePath(), new CharHandler[] {new LineHashComputer(consumer, f.file())}); } catch (IOException e) { throw new IllegalStateException("Failed to compute li...
[ "public", "static", "void", "computeLineHashesForIssueTracking", "(", "InputFile", "f", ",", "LineHashConsumer", "consumer", ")", "{", "try", "{", "readFile", "(", "f", ".", "inputStream", "(", ")", ",", "f", ".", "charset", "(", ")", ",", "f", ".", "absol...
Compute a MD5 hash of each line of the file after removing of all blank chars
[ "Compute", "a", "MD5", "hash", "of", "each", "line", "of", "the", "file", "after", "removing", "of", "all", "blank", "chars" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/batch/fs/internal/FileMetadata.java#L154-L160
16,323
SonarSource/sonarqube
server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/component/ComponentUuidFactoryWithMigration.java
ComponentUuidFactoryWithMigration.getOrCreateForKey
@Override public String getOrCreateForKey(String key) { return uuidsByDbKey.computeIfAbsent(key, k1 -> uuidsByMigratedKey.computeIfAbsent(k1, k2 -> Uuids.create())); }
java
@Override public String getOrCreateForKey(String key) { return uuidsByDbKey.computeIfAbsent(key, k1 -> uuidsByMigratedKey.computeIfAbsent(k1, k2 -> Uuids.create())); }
[ "@", "Override", "public", "String", "getOrCreateForKey", "(", "String", "key", ")", "{", "return", "uuidsByDbKey", ".", "computeIfAbsent", "(", "key", ",", "k1", "->", "uuidsByMigratedKey", ".", "computeIfAbsent", "(", "k1", ",", "k2", "->", "Uuids", ".", "...
Get UUID from component having the same key in database if it exists, otherwise look for migrated keys, and finally generate a new one.
[ "Get", "UUID", "from", "component", "having", "the", "same", "key", "in", "database", "if", "it", "exists", "otherwise", "look", "for", "migrated", "keys", "and", "finally", "generate", "a", "new", "one", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-ce-task-projectanalysis/src/main/java/org/sonar/ce/task/projectanalysis/component/ComponentUuidFactoryWithMigration.java#L122-L125
16,324
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/permission/index/WebAuthorizationTypeSupport.java
WebAuthorizationTypeSupport.createQueryFilter
public QueryBuilder createQueryFilter() { if (userSession.isRoot()) { return QueryBuilders.matchAllQuery(); } Integer userId = userSession.getUserId(); BoolQueryBuilder filter = boolQuery(); // anyone filter.should(QueryBuilders.termQuery(FIELD_ALLOW_ANYONE, true)); // users Opt...
java
public QueryBuilder createQueryFilter() { if (userSession.isRoot()) { return QueryBuilders.matchAllQuery(); } Integer userId = userSession.getUserId(); BoolQueryBuilder filter = boolQuery(); // anyone filter.should(QueryBuilders.termQuery(FIELD_ALLOW_ANYONE, true)); // users Opt...
[ "public", "QueryBuilder", "createQueryFilter", "(", ")", "{", "if", "(", "userSession", ".", "isRoot", "(", ")", ")", "{", "return", "QueryBuilders", ".", "matchAllQuery", "(", ")", ";", "}", "Integer", "userId", "=", "userSession", ".", "getUserId", "(", ...
Build a filter to restrict query to the documents on which user has read access.
[ "Build", "a", "filter", "to", "restrict", "query", "to", "the", "documents", "on", "which", "user", "has", "read", "access", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/permission/index/WebAuthorizationTypeSupport.java#L51-L77
16,325
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/permission/PermissionPrivilegeChecker.java
PermissionPrivilegeChecker.checkProjectAdmin
public static void checkProjectAdmin(UserSession userSession, String organizationUuid, Optional<ProjectId> projectId) { userSession.checkLoggedIn(); if (userSession.hasPermission(OrganizationPermission.ADMINISTER, organizationUuid)) { return; } if (projectId.isPresent()) { userSession.chec...
java
public static void checkProjectAdmin(UserSession userSession, String organizationUuid, Optional<ProjectId> projectId) { userSession.checkLoggedIn(); if (userSession.hasPermission(OrganizationPermission.ADMINISTER, organizationUuid)) { return; } if (projectId.isPresent()) { userSession.chec...
[ "public", "static", "void", "checkProjectAdmin", "(", "UserSession", "userSession", ",", "String", "organizationUuid", ",", "Optional", "<", "ProjectId", ">", "projectId", ")", "{", "userSession", ".", "checkLoggedIn", "(", ")", ";", "if", "(", "userSession", "....
Checks that user is administrator of the specified project, or of the specified organization if project is not defined. @throws org.sonar.server.exceptions.ForbiddenException if user is not administrator
[ "Checks", "that", "user", "is", "administrator", "of", "the", "specified", "project", "or", "of", "the", "specified", "organization", "if", "project", "is", "not", "defined", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/permission/PermissionPrivilegeChecker.java#L45-L57
16,326
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/util/ClassLoaderUtils.java
ClassLoaderUtils.listFiles
public static Collection<String> listFiles(ClassLoader classLoader, String rootPath) { return listResources(classLoader, rootPath, path -> !StringUtils.endsWith(path, "/")); }
java
public static Collection<String> listFiles(ClassLoader classLoader, String rootPath) { return listResources(classLoader, rootPath, path -> !StringUtils.endsWith(path, "/")); }
[ "public", "static", "Collection", "<", "String", ">", "listFiles", "(", "ClassLoader", "classLoader", ",", "String", "rootPath", ")", "{", "return", "listResources", "(", "classLoader", ",", "rootPath", ",", "path", "->", "!", "StringUtils", ".", "endsWith", "...
Finds files within a given directory and its subdirectories @param classLoader @param rootPath the root directory, for example org/sonar/sqale @return a list of relative paths, for example {"org/sonar/sqale/foo/bar.txt}. Never null.
[ "Finds", "files", "within", "a", "given", "directory", "and", "its", "subdirectories" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/util/ClassLoaderUtils.java#L50-L52
16,327
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/util/ClassLoaderUtils.java
ClassLoaderUtils.listResources
public static Collection<String> listResources(ClassLoader classLoader, String rootPath, Predicate<String> predicate) { String jarPath = null; JarFile jar = null; try { Collection<String> paths = new ArrayList<>(); URL root = classLoader.getResource(rootPath); if (root != null) { c...
java
public static Collection<String> listResources(ClassLoader classLoader, String rootPath, Predicate<String> predicate) { String jarPath = null; JarFile jar = null; try { Collection<String> paths = new ArrayList<>(); URL root = classLoader.getResource(rootPath); if (root != null) { c...
[ "public", "static", "Collection", "<", "String", ">", "listResources", "(", "ClassLoader", "classLoader", ",", "String", "rootPath", ",", "Predicate", "<", "String", ">", "predicate", ")", "{", "String", "jarPath", "=", "null", ";", "JarFile", "jar", "=", "n...
Finds directories and files within a given directory and its subdirectories. @param classLoader @param rootPath the root directory, for example org/sonar/sqale, or a file in this root directory, for example org/sonar/sqale/index.txt @param predicate @return a list of relative paths, for example {"org/sonar/sqale", ...
[ "Finds", "directories", "and", "files", "within", "a", "given", "directory", "and", "its", "subdirectories", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/util/ClassLoaderUtils.java#L62-L97
16,328
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/server/rule/RulesDefinitionI18nLoader.java
RulesDefinitionI18nLoader.load
public void load(RulesDefinition.NewRepository repo) { for (RulesDefinition.NewRule rule : repo.rules()) { String name = i18n.getName(repo.key(), rule.key()); if (StringUtils.isNotBlank(name)) { rule.setName(name); } String desc = i18n.getDescription(repo.key(), rule.key()); i...
java
public void load(RulesDefinition.NewRepository repo) { for (RulesDefinition.NewRule rule : repo.rules()) { String name = i18n.getName(repo.key(), rule.key()); if (StringUtils.isNotBlank(name)) { rule.setName(name); } String desc = i18n.getDescription(repo.key(), rule.key()); i...
[ "public", "void", "load", "(", "RulesDefinition", ".", "NewRepository", "repo", ")", "{", "for", "(", "RulesDefinition", ".", "NewRule", "rule", ":", "repo", ".", "rules", "(", ")", ")", "{", "String", "name", "=", "i18n", ".", "getName", "(", "repo", ...
Loads descriptions of rules and related rule parameters. Existing descriptions are overridden if English labels exist in bundles.
[ "Loads", "descriptions", "of", "rules", "and", "related", "rule", "parameters", ".", "Existing", "descriptions", "are", "overridden", "if", "English", "labels", "exist", "in", "bundles", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/server/rule/RulesDefinitionI18nLoader.java#L49-L68
16,329
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/platform/db/migration/AutoDbMigration.java
AutoDbMigration.hackFixForProjectMeasureTreeQueries
private static void hackFixForProjectMeasureTreeQueries(Connection connection) { int metricId = 1; try (PreparedStatement preparedStatement = connection.prepareStatement("insert into PROJECT_MEASURES (METRIC_ID,COMPONENT_UUID,ANALYSIS_UUID) values (?,?,?);")) { batchExecute( 1, 1000, prepa...
java
private static void hackFixForProjectMeasureTreeQueries(Connection connection) { int metricId = 1; try (PreparedStatement preparedStatement = connection.prepareStatement("insert into PROJECT_MEASURES (METRIC_ID,COMPONENT_UUID,ANALYSIS_UUID) values (?,?,?);")) { batchExecute( 1, 1000, prepa...
[ "private", "static", "void", "hackFixForProjectMeasureTreeQueries", "(", "Connection", "connection", ")", "{", "int", "metricId", "=", "1", ";", "try", "(", "PreparedStatement", "preparedStatement", "=", "connection", ".", "prepareStatement", "(", "\"insert into PROJECT...
see SONAR-8586
[ "see", "SONAR", "-", "8586" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/platform/db/migration/AutoDbMigration.java#L102-L116
16,330
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/batch/bootstrap/ProjectReactor.java
ProjectReactor.collectProjects
private static List<ProjectDefinition> collectProjects(ProjectDefinition def, List<ProjectDefinition> collected) { collected.add(def); for (ProjectDefinition child : def.getSubProjects()) { collectProjects(child, collected); } return collected; }
java
private static List<ProjectDefinition> collectProjects(ProjectDefinition def, List<ProjectDefinition> collected) { collected.add(def); for (ProjectDefinition child : def.getSubProjects()) { collectProjects(child, collected); } return collected; }
[ "private", "static", "List", "<", "ProjectDefinition", ">", "collectProjects", "(", "ProjectDefinition", "def", ",", "List", "<", "ProjectDefinition", ">", "collected", ")", "{", "collected", ".", "add", "(", "def", ")", ";", "for", "(", "ProjectDefinition", "...
Populates list of projects from hierarchy.
[ "Populates", "list", "of", "projects", "from", "hierarchy", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/batch/bootstrap/ProjectReactor.java#L53-L59
16,331
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/source/SourceService.java
SourceService.getLines
public Optional<Iterable<DbFileSources.Line>> getLines(DbSession dbSession, String fileUuid, int from, int toInclusive) { return getLines(dbSession, fileUuid, from, toInclusive, Function.identity()); }
java
public Optional<Iterable<DbFileSources.Line>> getLines(DbSession dbSession, String fileUuid, int from, int toInclusive) { return getLines(dbSession, fileUuid, from, toInclusive, Function.identity()); }
[ "public", "Optional", "<", "Iterable", "<", "DbFileSources", ".", "Line", ">", ">", "getLines", "(", "DbSession", "dbSession", ",", "String", "fileUuid", ",", "int", "from", ",", "int", "toInclusive", ")", "{", "return", "getLines", "(", "dbSession", ",", ...
Returns a range of lines as raw db data. User permission is not verified. @param from starts from 1 @param toInclusive starts from 1, must be greater than or equal param {@code from}
[ "Returns", "a", "range", "of", "lines", "as", "raw", "db", "data", ".", "User", "permission", "is", "not", "verified", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/source/SourceService.java#L49-L51
16,332
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/source/SourceService.java
SourceService.getLinesAsRawText
public Optional<Iterable<String>> getLinesAsRawText(DbSession dbSession, String fileUuid, int from, int toInclusive) { return getLines(dbSession, fileUuid, from, toInclusive, DbFileSources.Line::getSource); }
java
public Optional<Iterable<String>> getLinesAsRawText(DbSession dbSession, String fileUuid, int from, int toInclusive) { return getLines(dbSession, fileUuid, from, toInclusive, DbFileSources.Line::getSource); }
[ "public", "Optional", "<", "Iterable", "<", "String", ">", ">", "getLinesAsRawText", "(", "DbSession", "dbSession", ",", "String", "fileUuid", ",", "int", "from", ",", "int", "toInclusive", ")", "{", "return", "getLines", "(", "dbSession", ",", "fileUuid", "...
Returns a range of lines as raw text. @see #getLines(DbSession, String, int, int)
[ "Returns", "a", "range", "of", "lines", "as", "raw", "text", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/source/SourceService.java#L57-L59
16,333
SonarSource/sonarqube
sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/filesystem/MetadataGenerator.java
MetadataGenerator.setMetadata
public void setMetadata(String moduleKeyWithBranch, final DefaultInputFile inputFile, Charset defaultEncoding) { CharsetDetector charsetDetector = new CharsetDetector(inputFile.path(), defaultEncoding); try { Charset charset; if (charsetDetector.run()) { charset = charsetDetector.charset(); ...
java
public void setMetadata(String moduleKeyWithBranch, final DefaultInputFile inputFile, Charset defaultEncoding) { CharsetDetector charsetDetector = new CharsetDetector(inputFile.path(), defaultEncoding); try { Charset charset; if (charsetDetector.run()) { charset = charsetDetector.charset(); ...
[ "public", "void", "setMetadata", "(", "String", "moduleKeyWithBranch", ",", "final", "DefaultInputFile", "inputFile", ",", "Charset", "defaultEncoding", ")", "{", "CharsetDetector", "charsetDetector", "=", "new", "CharsetDetector", "(", "inputFile", ".", "path", "(", ...
Sets all metadata in the file, including charset and status. It is an expensive computation, reading the entire file.
[ "Sets", "all", "metadata", "in", "the", "file", "including", "charset", "and", "status", ".", "It", "is", "an", "expensive", "computation", "reading", "the", "entire", "file", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-scanner-engine/src/main/java/org/sonar/scanner/scan/filesystem/MetadataGenerator.java#L55-L74
16,334
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java
Request.mandatoryParam
public String mandatoryParam(String key) { String value = param(key); checkArgument(value != null && !value.isEmpty(), format(MSG_PARAMETER_MISSING, key)); return value; }
java
public String mandatoryParam(String key) { String value = param(key); checkArgument(value != null && !value.isEmpty(), format(MSG_PARAMETER_MISSING, key)); return value; }
[ "public", "String", "mandatoryParam", "(", "String", "key", ")", "{", "String", "value", "=", "param", "(", "key", ")", ";", "checkArgument", "(", "value", "!=", "null", "&&", "!", "value", ".", "isEmpty", "(", ")", ",", "format", "(", "MSG_PARAMETER_MIS...
Returns a non-null value. To be used when parameter is required or has a default value. @throws java.lang.IllegalArgumentException is value is null or blank
[ "Returns", "a", "non", "-", "null", "value", ".", "To", "be", "used", "when", "parameter", "is", "required", "or", "has", "a", "default", "value", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java#L78-L82
16,335
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java
Request.mandatoryParamAsBoolean
public boolean mandatoryParamAsBoolean(String key) { String s = mandatoryParam(key); return parseBoolean(key, s); }
java
public boolean mandatoryParamAsBoolean(String key) { String s = mandatoryParam(key); return parseBoolean(key, s); }
[ "public", "boolean", "mandatoryParamAsBoolean", "(", "String", "key", ")", "{", "String", "s", "=", "mandatoryParam", "(", "key", ")", ";", "return", "parseBoolean", "(", "key", ",", "s", ")", ";", "}" ]
Returns a boolean value. To be used when parameter is required or has a default value. @throws java.lang.IllegalArgumentException is value is null or blank
[ "Returns", "a", "boolean", "value", ".", "To", "be", "used", "when", "parameter", "is", "required", "or", "has", "a", "default", "value", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java#L89-L92
16,336
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java
Request.mandatoryParamAsInt
public int mandatoryParamAsInt(String key) { String s = mandatoryParam(key); return parseInt(key, s); }
java
public int mandatoryParamAsInt(String key) { String s = mandatoryParam(key); return parseInt(key, s); }
[ "public", "int", "mandatoryParamAsInt", "(", "String", "key", ")", "{", "String", "s", "=", "mandatoryParam", "(", "key", ")", ";", "return", "parseInt", "(", "key", ",", "s", ")", ";", "}" ]
Returns an int value. To be used when parameter is required or has a default value. @throws java.lang.IllegalArgumentException is value is null or blank
[ "Returns", "an", "int", "value", ".", "To", "be", "used", "when", "parameter", "is", "required", "or", "has", "a", "default", "value", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java#L99-L102
16,337
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java
Request.mandatoryParamAsLong
public long mandatoryParamAsLong(String key) { String s = mandatoryParam(key); return parseLong(key, s); }
java
public long mandatoryParamAsLong(String key) { String s = mandatoryParam(key); return parseLong(key, s); }
[ "public", "long", "mandatoryParamAsLong", "(", "String", "key", ")", "{", "String", "s", "=", "mandatoryParam", "(", "key", ")", ";", "return", "parseLong", "(", "key", ",", "s", ")", ";", "}" ]
Returns a long value. To be used when parameter is required or has a default value. @throws java.lang.IllegalArgumentException is value is null or blank
[ "Returns", "a", "long", "value", ".", "To", "be", "used", "when", "parameter", "is", "required", "or", "has", "a", "default", "value", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/server/ws/Request.java#L109-L112
16,338
SonarSource/sonarqube
sonar-core/src/main/java/org/sonar/core/config/Logback.java
Logback.configure
private static void configure(InputStream input, Map<String, String> substitutionVariables) { LoggerContext lc = (LoggerContext) LoggerFactory.getILoggerFactory(); try { JoranConfigurator configurator = new JoranConfigurator(); configurator.setContext(configureContext(lc, substitutionVariables)); ...
java
private static void configure(InputStream input, Map<String, String> substitutionVariables) { LoggerContext lc = (LoggerContext) LoggerFactory.getILoggerFactory(); try { JoranConfigurator configurator = new JoranConfigurator(); configurator.setContext(configureContext(lc, substitutionVariables)); ...
[ "private", "static", "void", "configure", "(", "InputStream", "input", ",", "Map", "<", "String", ",", "String", ">", "substitutionVariables", ")", "{", "LoggerContext", "lc", "=", "(", "LoggerContext", ")", "LoggerFactory", ".", "getILoggerFactory", "(", ")", ...
Note that this method closes the input stream
[ "Note", "that", "this", "method", "closes", "the", "input", "stream" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-core/src/main/java/org/sonar/core/config/Logback.java#L66-L78
16,339
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/permission/PermissionTemplateService.java
PermissionTemplateService.applyAndCommit
public void applyAndCommit(DbSession dbSession, PermissionTemplateDto template, Collection<ComponentDto> projects) { if (projects.isEmpty()) { return; } for (ComponentDto project : projects) { copyPermissions(dbSession, template, project, null); } projectIndexers.commitAndIndex(dbSessio...
java
public void applyAndCommit(DbSession dbSession, PermissionTemplateDto template, Collection<ComponentDto> projects) { if (projects.isEmpty()) { return; } for (ComponentDto project : projects) { copyPermissions(dbSession, template, project, null); } projectIndexers.commitAndIndex(dbSessio...
[ "public", "void", "applyAndCommit", "(", "DbSession", "dbSession", ",", "PermissionTemplateDto", "template", ",", "Collection", "<", "ComponentDto", ">", "projects", ")", "{", "if", "(", "projects", ".", "isEmpty", "(", ")", ")", "{", "return", ";", "}", "fo...
Apply a permission template to a set of projects. Authorization to administrate these projects is not verified. The projects must exist, so the "project creator" permissions defined in the template are ignored.
[ "Apply", "a", "permission", "template", "to", "a", "set", "of", "projects", ".", "Authorization", "to", "administrate", "these", "projects", "is", "not", "verified", ".", "The", "projects", "must", "exist", "so", "the", "project", "creator", "permissions", "de...
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/permission/PermissionTemplateService.java#L92-L101
16,340
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/permission/PermissionTemplateService.java
PermissionTemplateService.findTemplate
@CheckForNull private PermissionTemplateDto findTemplate(DbSession dbSession, ComponentDto component) { String organizationUuid = component.getOrganizationUuid(); List<PermissionTemplateDto> allPermissionTemplates = dbClient.permissionTemplateDao().selectAll(dbSession, organizationUuid, null); List<Permis...
java
@CheckForNull private PermissionTemplateDto findTemplate(DbSession dbSession, ComponentDto component) { String organizationUuid = component.getOrganizationUuid(); List<PermissionTemplateDto> allPermissionTemplates = dbClient.permissionTemplateDao().selectAll(dbSession, organizationUuid, null); List<Permis...
[ "@", "CheckForNull", "private", "PermissionTemplateDto", "findTemplate", "(", "DbSession", "dbSession", ",", "ComponentDto", "component", ")", "{", "String", "organizationUuid", "=", "component", ".", "getOrganizationUuid", "(", ")", ";", "List", "<", "PermissionTempl...
Return the permission template for the given component. If no template key pattern match then consider default template for the component qualifier.
[ "Return", "the", "permission", "template", "for", "the", "given", "component", ".", "If", "no", "template", "key", "pattern", "match", "then", "consider", "default", "template", "for", "the", "component", "qualifier", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/permission/PermissionTemplateService.java#L181-L217
16,341
SonarSource/sonarqube
server/sonar-server-common/src/main/java/org/sonar/server/rule/index/RuleIndex.java
RuleIndex.searchAll
public Iterator<Integer> searchAll(RuleQuery query) { SearchRequestBuilder esSearch = client .prepareSearch(TYPE_RULE) .setScroll(TimeValue.timeValueMinutes(SCROLL_TIME_IN_MINUTES)); optimizeScrollRequest(esSearch); QueryBuilder qb = buildQuery(query); Map<String, QueryBuilder> filters = bu...
java
public Iterator<Integer> searchAll(RuleQuery query) { SearchRequestBuilder esSearch = client .prepareSearch(TYPE_RULE) .setScroll(TimeValue.timeValueMinutes(SCROLL_TIME_IN_MINUTES)); optimizeScrollRequest(esSearch); QueryBuilder qb = buildQuery(query); Map<String, QueryBuilder> filters = bu...
[ "public", "Iterator", "<", "Integer", ">", "searchAll", "(", "RuleQuery", "query", ")", "{", "SearchRequestBuilder", "esSearch", "=", "client", ".", "prepareSearch", "(", "TYPE_RULE", ")", ".", "setScroll", "(", "TimeValue", ".", "timeValueMinutes", "(", "SCROLL...
Return all rule ids matching the search query, without pagination nor facets
[ "Return", "all", "rule", "ids", "matching", "the", "search", "query", "without", "pagination", "nor", "facets" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server-common/src/main/java/org/sonar/server/rule/index/RuleIndex.java#L172-L189
16,342
SonarSource/sonarqube
server/sonar-server-common/src/main/java/org/sonar/server/platform/StartupMetadataProvider.java
StartupMetadataProvider.load
private static StartupMetadata load(DbClient dbClient) { try (DbSession dbSession = dbClient.openSession(false)) { String startedAt = selectProperty(dbClient, dbSession, SERVER_STARTTIME); return new StartupMetadata(DateUtils.parseDateTime(startedAt).getTime()); } }
java
private static StartupMetadata load(DbClient dbClient) { try (DbSession dbSession = dbClient.openSession(false)) { String startedAt = selectProperty(dbClient, dbSession, SERVER_STARTTIME); return new StartupMetadata(DateUtils.parseDateTime(startedAt).getTime()); } }
[ "private", "static", "StartupMetadata", "load", "(", "DbClient", "dbClient", ")", "{", "try", "(", "DbSession", "dbSession", "=", "dbClient", ".", "openSession", "(", "false", ")", ")", "{", "String", "startedAt", "=", "selectProperty", "(", "dbClient", ",", ...
Load from database
[ "Load", "from", "database" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server-common/src/main/java/org/sonar/server/platform/StartupMetadataProvider.java#L68-L73
16,343
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java
Platform.startLevel34Containers
private void startLevel34Containers() { level3 = start(new PlatformLevel3(level2)); level4 = start(new PlatformLevel4(level3, level4AddedComponents)); }
java
private void startLevel34Containers() { level3 = start(new PlatformLevel3(level2)); level4 = start(new PlatformLevel4(level3, level4AddedComponents)); }
[ "private", "void", "startLevel34Containers", "(", ")", "{", "level3", "=", "start", "(", "new", "PlatformLevel3", "(", "level2", ")", ")", ";", "level4", "=", "start", "(", "new", "PlatformLevel4", "(", "level3", ",", "level4AddedComponents", ")", ")", ";", ...
Starts level 3 and 4
[ "Starts", "level", "3", "and", "4" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java#L183-L186
16,344
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java
Platform.doStop
public void doStop() { try { stopAutoStarter(); stopSafeModeContainer(); stopLevel234Containers(); stopLevel1Container(); currentLevel = null; dbConnected = false; started = false; } catch (Exception e) { LOGGER.error("Fail to stop server - ignored", e); } }
java
public void doStop() { try { stopAutoStarter(); stopSafeModeContainer(); stopLevel234Containers(); stopLevel1Container(); currentLevel = null; dbConnected = false; started = false; } catch (Exception e) { LOGGER.error("Fail to stop server - ignored", e); } }
[ "public", "void", "doStop", "(", ")", "{", "try", "{", "stopAutoStarter", "(", ")", ";", "stopSafeModeContainer", "(", ")", ";", "stopLevel234Containers", "(", ")", ";", "stopLevel1Container", "(", ")", ";", "currentLevel", "=", "null", ";", "dbConnected", "...
Do not rename "stop"
[ "Do", "not", "rename", "stop" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/platform/Platform.java#L261-L273
16,345
SonarSource/sonarqube
server/sonar-process/src/main/java/org/sonar/process/Jmx.java
Jmx.register
public static void register(String name, Object instance) { try { Class<Object> mbeanInterface = guessMBeanInterface(instance); ManagementFactory.getPlatformMBeanServer().registerMBean(new StandardMBean(instance, mbeanInterface), new ObjectName(name)); } catch (MalformedObjectNameException | NotCom...
java
public static void register(String name, Object instance) { try { Class<Object> mbeanInterface = guessMBeanInterface(instance); ManagementFactory.getPlatformMBeanServer().registerMBean(new StandardMBean(instance, mbeanInterface), new ObjectName(name)); } catch (MalformedObjectNameException | NotCom...
[ "public", "static", "void", "register", "(", "String", "name", ",", "Object", "instance", ")", "{", "try", "{", "Class", "<", "Object", ">", "mbeanInterface", "=", "guessMBeanInterface", "(", "instance", ")", ";", "ManagementFactory", ".", "getPlatformMBeanServe...
Register a MBean to JMX server
[ "Register", "a", "MBean", "to", "JMX", "server" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-process/src/main/java/org/sonar/process/Jmx.java#L43-L51
16,346
SonarSource/sonarqube
server/sonar-process/src/main/java/org/sonar/process/Jmx.java
Jmx.unregister
public static void unregister(String name) { try { ManagementFactory.getPlatformMBeanServer().unregisterMBean(new ObjectName(name)); } catch (Exception e) { LoggerFactory.getLogger(Jmx.class).warn("Can not unregister MBean [{}]", name, e); } }
java
public static void unregister(String name) { try { ManagementFactory.getPlatformMBeanServer().unregisterMBean(new ObjectName(name)); } catch (Exception e) { LoggerFactory.getLogger(Jmx.class).warn("Can not unregister MBean [{}]", name, e); } }
[ "public", "static", "void", "unregister", "(", "String", "name", ")", "{", "try", "{", "ManagementFactory", ".", "getPlatformMBeanServer", "(", ")", ".", "unregisterMBean", "(", "new", "ObjectName", "(", "name", ")", ")", ";", "}", "catch", "(", "Exception",...
Unregister a MBean from JMX server. Errors are ignored and logged as warnings.
[ "Unregister", "a", "MBean", "from", "JMX", "server", ".", "Errors", "are", "ignored", "and", "logged", "as", "warnings", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-process/src/main/java/org/sonar/process/Jmx.java#L80-L86
16,347
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/platform/BackendCleanup.java
BackendCleanup.clearIndex
public void clearIndex(Index index) { BulkIndexer.delete(esClient, IndexType.main(index, index.getName()), esClient.prepareSearch(index).setQuery(matchAllQuery())); }
java
public void clearIndex(Index index) { BulkIndexer.delete(esClient, IndexType.main(index, index.getName()), esClient.prepareSearch(index).setQuery(matchAllQuery())); }
[ "public", "void", "clearIndex", "(", "Index", "index", ")", "{", "BulkIndexer", ".", "delete", "(", "esClient", ",", "IndexType", ".", "main", "(", "index", ",", "index", ".", "getName", "(", ")", ")", ",", "esClient", ".", "prepareSearch", "(", "index",...
Completely remove a index with all types
[ "Completely", "remove", "a", "index", "with", "all", "types" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/platform/BackendCleanup.java#L171-L173
16,348
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/platform/BackendCleanup.java
BackendCleanup.truncateOrganizations
private static void truncateOrganizations(String tableName, Statement ddlStatement, Connection connection) throws SQLException { try (PreparedStatement preparedStatement = connection.prepareStatement("delete from organizations where kee <> ?")) { preparedStatement.setString(1, "default-organization"); p...
java
private static void truncateOrganizations(String tableName, Statement ddlStatement, Connection connection) throws SQLException { try (PreparedStatement preparedStatement = connection.prepareStatement("delete from organizations where kee <> ?")) { preparedStatement.setString(1, "default-organization"); p...
[ "private", "static", "void", "truncateOrganizations", "(", "String", "tableName", ",", "Statement", "ddlStatement", ",", "Connection", "connection", ")", "throws", "SQLException", "{", "try", "(", "PreparedStatement", "preparedStatement", "=", "connection", ".", "prep...
Default organization must never be deleted
[ "Default", "organization", "must", "never", "be", "deleted" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/platform/BackendCleanup.java#L189-L196
16,349
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/platform/BackendCleanup.java
BackendCleanup.truncateUsers
private static void truncateUsers(String tableName, Statement ddlStatement, Connection connection) throws SQLException { try (PreparedStatement preparedStatement = connection.prepareStatement("delete from users where login <> ?")) { preparedStatement.setString(1, "admin"); preparedStatement.execute(); ...
java
private static void truncateUsers(String tableName, Statement ddlStatement, Connection connection) throws SQLException { try (PreparedStatement preparedStatement = connection.prepareStatement("delete from users where login <> ?")) { preparedStatement.setString(1, "admin"); preparedStatement.execute(); ...
[ "private", "static", "void", "truncateUsers", "(", "String", "tableName", ",", "Statement", "ddlStatement", ",", "Connection", "connection", ")", "throws", "SQLException", "{", "try", "(", "PreparedStatement", "preparedStatement", "=", "connection", ".", "prepareState...
User admin must never be deleted.
[ "User", "admin", "must", "never", "be", "deleted", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/platform/BackendCleanup.java#L201-L215
16,350
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/permission/ws/template/DeleteTemplateAction.java
DeleteTemplateAction.updateViewDefaultTemplateWhenGovernanceIsNotInstalled
private void updateViewDefaultTemplateWhenGovernanceIsNotInstalled(DbSession dbSession, PermissionTemplateDto template, DefaultTemplates defaultTemplates) { String viewDefaultTemplateUuid = defaultTemplates.getApplicationsUuid(); if (viewDefaultTemplateUuid != null && viewDefaultTemplateUuid.equals(template.get...
java
private void updateViewDefaultTemplateWhenGovernanceIsNotInstalled(DbSession dbSession, PermissionTemplateDto template, DefaultTemplates defaultTemplates) { String viewDefaultTemplateUuid = defaultTemplates.getApplicationsUuid(); if (viewDefaultTemplateUuid != null && viewDefaultTemplateUuid.equals(template.get...
[ "private", "void", "updateViewDefaultTemplateWhenGovernanceIsNotInstalled", "(", "DbSession", "dbSession", ",", "PermissionTemplateDto", "template", ",", "DefaultTemplates", "defaultTemplates", ")", "{", "String", "viewDefaultTemplateUuid", "=", "defaultTemplates", ".", "getApp...
The default template for view can be removed when Governance is not installed. To avoid keeping a reference to a non existing template, we update the default templates.
[ "The", "default", "template", "for", "view", "can", "be", "removed", "when", "Governance", "is", "not", "installed", ".", "To", "avoid", "keeping", "a", "reference", "to", "a", "non", "existing", "template", "we", "update", "the", "default", "templates", "."...
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/permission/ws/template/DeleteTemplateAction.java#L103-L109
16,351
SonarSource/sonarqube
server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java
ClusterSettings.shouldStartHazelcast
public static boolean shouldStartHazelcast(AppSettings appSettings) { return isClusterEnabled(appSettings.getProps()) && toNodeType(appSettings.getProps()).equals(NodeType.APPLICATION); }
java
public static boolean shouldStartHazelcast(AppSettings appSettings) { return isClusterEnabled(appSettings.getProps()) && toNodeType(appSettings.getProps()).equals(NodeType.APPLICATION); }
[ "public", "static", "boolean", "shouldStartHazelcast", "(", "AppSettings", "appSettings", ")", "{", "return", "isClusterEnabled", "(", "appSettings", ".", "getProps", "(", ")", ")", "&&", "toNodeType", "(", "appSettings", ".", "getProps", "(", ")", ")", ".", "...
Hazelcast must be started when cluster is activated on all nodes but search ones
[ "Hazelcast", "must", "be", "started", "when", "cluster", "is", "activated", "on", "all", "nodes", "but", "search", "ones" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-main/src/main/java/org/sonar/application/config/ClusterSettings.java#L159-L161
16,352
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/component/ComponentUpdateDto.java
ComponentUpdateDto.copyFrom
public static ComponentUpdateDto copyFrom(ComponentDto from) { return new ComponentUpdateDto() .setUuid(from.uuid()) .setBChanged(false) .setBKey(from.getDbKey()) .setBCopyComponentUuid(from.getCopyResourceUuid()) .setBDescription(from.description()) .setBEnabled(from.isEnabled()...
java
public static ComponentUpdateDto copyFrom(ComponentDto from) { return new ComponentUpdateDto() .setUuid(from.uuid()) .setBChanged(false) .setBKey(from.getDbKey()) .setBCopyComponentUuid(from.getCopyResourceUuid()) .setBDescription(from.description()) .setBEnabled(from.isEnabled()...
[ "public", "static", "ComponentUpdateDto", "copyFrom", "(", "ComponentDto", "from", ")", "{", "return", "new", "ComponentUpdateDto", "(", ")", ".", "setUuid", "(", "from", ".", "uuid", "(", ")", ")", ".", "setBChanged", "(", "false", ")", ".", "setBKey", "(...
Copy the A-fields to B-fields. The field bChanged is kept to false.
[ "Copy", "the", "A", "-", "fields", "to", "B", "-", "fields", ".", "The", "field", "bChanged", "is", "kept", "to", "false", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/component/ComponentUpdateDto.java#L187-L204
16,353
SonarSource/sonarqube
server/sonar-process/src/main/java/org/sonar/process/cluster/hz/HazelcastMemberBuilder.java
HazelcastMemberBuilder.setMembers
public HazelcastMemberBuilder setMembers(Collection<String> c) { this.members = c.stream() .map(host -> host.contains(":") ? host : format("%s:%s", host, CLUSTER_NODE_HZ_PORT.getDefaultValue())) .collect(Collectors.toList()); return this; }
java
public HazelcastMemberBuilder setMembers(Collection<String> c) { this.members = c.stream() .map(host -> host.contains(":") ? host : format("%s:%s", host, CLUSTER_NODE_HZ_PORT.getDefaultValue())) .collect(Collectors.toList()); return this; }
[ "public", "HazelcastMemberBuilder", "setMembers", "(", "Collection", "<", "String", ">", "c", ")", "{", "this", ".", "members", "=", "c", ".", "stream", "(", ")", ".", "map", "(", "host", "->", "host", ".", "contains", "(", "\":\"", ")", "?", "host", ...
Adds references to cluster members. If port is missing, then default port is automatically added.
[ "Adds", "references", "to", "cluster", "members", ".", "If", "port", "is", "missing", "then", "default", "port", "is", "automatically", "added", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-process/src/main/java/org/sonar/process/cluster/hz/HazelcastMemberBuilder.java#L80-L85
16,354
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/utils/ManifestUtils.java
ManifestUtils.getPropertyValues
public static List<String> getPropertyValues(ClassLoader classloader, String key) { List<String> values = new ArrayList<>(); try { Enumeration<URL> resources = classloader.getResources("META-INF/MANIFEST.MF"); while (resources.hasMoreElements()) { Manifest manifest = new Manifest(resources.n...
java
public static List<String> getPropertyValues(ClassLoader classloader, String key) { List<String> values = new ArrayList<>(); try { Enumeration<URL> resources = classloader.getResources("META-INF/MANIFEST.MF"); while (resources.hasMoreElements()) { Manifest manifest = new Manifest(resources.n...
[ "public", "static", "List", "<", "String", ">", "getPropertyValues", "(", "ClassLoader", "classloader", ",", "String", "key", ")", "{", "List", "<", "String", ">", "values", "=", "new", "ArrayList", "<>", "(", ")", ";", "try", "{", "Enumeration", "<", "U...
Search for a property in all the manifests found in the classloader @return the values, an empty list if the property is not found.
[ "Search", "for", "a", "property", "in", "all", "the", "manifests", "found", "in", "the", "classloader" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/utils/ManifestUtils.java#L43-L59
16,355
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/property/InternalPropertiesDao.java
InternalPropertiesDao.saveAsEmpty
public void saveAsEmpty(DbSession dbSession, String key) { checkKey(key); InternalPropertiesMapper mapper = getMapper(dbSession); mapper.deleteByKey(key); mapper.insertAsEmpty(key, system2.now()); }
java
public void saveAsEmpty(DbSession dbSession, String key) { checkKey(key); InternalPropertiesMapper mapper = getMapper(dbSession); mapper.deleteByKey(key); mapper.insertAsEmpty(key, system2.now()); }
[ "public", "void", "saveAsEmpty", "(", "DbSession", "dbSession", ",", "String", "key", ")", "{", "checkKey", "(", "key", ")", ";", "InternalPropertiesMapper", "mapper", "=", "getMapper", "(", "dbSession", ")", ";", "mapper", ".", "deleteByKey", "(", "key", ")...
Save a property which value is empty.
[ "Save", "a", "property", "which", "value", "is", "empty", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/property/InternalPropertiesDao.java#L84-L90
16,356
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/property/InternalPropertiesDao.java
InternalPropertiesDao.selectByKey
public Optional<String> selectByKey(DbSession dbSession, String key) { checkKey(key); InternalPropertiesMapper mapper = getMapper(dbSession); InternalPropertyDto res = enforceSingleElement(key, mapper.selectAsText(singletonList(key))); if (res == null) { return Optional.empty(); } if (res...
java
public Optional<String> selectByKey(DbSession dbSession, String key) { checkKey(key); InternalPropertiesMapper mapper = getMapper(dbSession); InternalPropertyDto res = enforceSingleElement(key, mapper.selectAsText(singletonList(key))); if (res == null) { return Optional.empty(); } if (res...
[ "public", "Optional", "<", "String", ">", "selectByKey", "(", "DbSession", "dbSession", ",", "String", "key", ")", "{", "checkKey", "(", "key", ")", ";", "InternalPropertiesMapper", "mapper", "=", "getMapper", "(", "dbSession", ")", ";", "InternalPropertyDto", ...
No streaming of value
[ "No", "streaming", "of", "value" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/property/InternalPropertiesDao.java#L143-L165
16,357
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java
UserDao.selectByIds
public List<UserDto> selectByIds(DbSession session, Collection<Integer> ids) { return executeLargeInputs(ids, mapper(session)::selectByIds); }
java
public List<UserDto> selectByIds(DbSession session, Collection<Integer> ids) { return executeLargeInputs(ids, mapper(session)::selectByIds); }
[ "public", "List", "<", "UserDto", ">", "selectByIds", "(", "DbSession", "session", ",", "Collection", "<", "Integer", ">", "ids", ")", "{", "return", "executeLargeInputs", "(", "ids", ",", "mapper", "(", "session", ")", "::", "selectByIds", ")", ";", "}" ]
Select users by ids, including disabled users. An empty list is returned if list of ids is empty, without any db round trips. Used by the Governance plugin
[ "Select", "users", "by", "ids", "including", "disabled", "users", ".", "An", "empty", "list", "is", "returned", "if", "list", "of", "ids", "is", "empty", "without", "any", "db", "round", "trips", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java#L71-L73
16,358
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java
UserDao.selectByLogins
public List<UserDto> selectByLogins(DbSession session, Collection<String> logins) { return executeLargeInputs(logins, mapper(session)::selectByLogins); }
java
public List<UserDto> selectByLogins(DbSession session, Collection<String> logins) { return executeLargeInputs(logins, mapper(session)::selectByLogins); }
[ "public", "List", "<", "UserDto", ">", "selectByLogins", "(", "DbSession", "session", ",", "Collection", "<", "String", ">", "logins", ")", "{", "return", "executeLargeInputs", "(", "logins", ",", "mapper", "(", "session", ")", "::", "selectByLogins", ")", "...
Select users by logins, including disabled users. An empty list is returned if list of logins is empty, without any db round trips.
[ "Select", "users", "by", "logins", "including", "disabled", "users", ".", "An", "empty", "list", "is", "returned", "if", "list", "of", "logins", "is", "empty", "without", "any", "db", "round", "trips", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java#L85-L87
16,359
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java
UserDao.selectByUuids
public List<UserDto> selectByUuids(DbSession session, Collection<String> uuids) { return executeLargeInputs(uuids, mapper(session)::selectByUuids); }
java
public List<UserDto> selectByUuids(DbSession session, Collection<String> uuids) { return executeLargeInputs(uuids, mapper(session)::selectByUuids); }
[ "public", "List", "<", "UserDto", ">", "selectByUuids", "(", "DbSession", "session", ",", "Collection", "<", "String", ">", "uuids", ")", "{", "return", "executeLargeInputs", "(", "uuids", ",", "mapper", "(", "session", ")", "::", "selectByUuids", ")", ";", ...
Select users by uuids, including disabled users. An empty list is returned if list of uuids is empty, without any db round trips.
[ "Select", "users", "by", "uuids", "including", "disabled", "users", ".", "An", "empty", "list", "is", "returned", "if", "list", "of", "uuids", "is", "empty", "without", "any", "db", "round", "trips", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java#L93-L95
16,360
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java
UserDao.selectByEmail
public List<UserDto> selectByEmail(DbSession dbSession, String emailCaseInsensitive) { return mapper(dbSession).selectByEmail(emailCaseInsensitive.toLowerCase(ENGLISH)); }
java
public List<UserDto> selectByEmail(DbSession dbSession, String emailCaseInsensitive) { return mapper(dbSession).selectByEmail(emailCaseInsensitive.toLowerCase(ENGLISH)); }
[ "public", "List", "<", "UserDto", ">", "selectByEmail", "(", "DbSession", "dbSession", ",", "String", "emailCaseInsensitive", ")", "{", "return", "mapper", "(", "dbSession", ")", ".", "selectByEmail", "(", "emailCaseInsensitive", ".", "toLowerCase", "(", "ENGLISH"...
Search for an active user with the given emailCaseInsensitive exits in database Select is case insensitive. Result for searching '[email protected]' or '[email protected]' is the same
[ "Search", "for", "an", "active", "user", "with", "the", "given", "emailCaseInsensitive", "exits", "in", "database" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/user/UserDao.java#L167-L169
16,361
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/issue/NoSonarFilter.java
NoSonarFilter.noSonarInFile
public NoSonarFilter noSonarInFile(InputFile inputFile, Set<Integer> noSonarLines) { ((DefaultInputFile) inputFile).noSonarAt(noSonarLines); return this; }
java
public NoSonarFilter noSonarInFile(InputFile inputFile, Set<Integer> noSonarLines) { ((DefaultInputFile) inputFile).noSonarAt(noSonarLines); return this; }
[ "public", "NoSonarFilter", "noSonarInFile", "(", "InputFile", "inputFile", ",", "Set", "<", "Integer", ">", "noSonarLines", ")", "{", "(", "(", "DefaultInputFile", ")", "inputFile", ")", ".", "noSonarAt", "(", "noSonarLines", ")", ";", "return", "this", ";", ...
Register lines in a file that contains the NOSONAR flag. @param inputFile @param noSonarLines Line number starts at 1 in a file @since 5.0 @since 7.6 the method can be called multiple times by different sensors, and NOSONAR lines are merged
[ "Register", "lines", "in", "a", "file", "that", "contains", "the", "NOSONAR", "flag", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/issue/NoSonarFilter.java#L47-L50
16,362
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/issue/index/IssueIndex.java
IssueIndex.configureRouting
private static void configureRouting(IssueQuery query, SearchOptions options, SearchRequestBuilder requestBuilder) { Collection<String> uuids = query.projectUuids(); if (!uuids.isEmpty() && options.getFacets().isEmpty()) { requestBuilder.setRouting(uuids.stream().map(AuthorizationDoc::idOf).toArray(String...
java
private static void configureRouting(IssueQuery query, SearchOptions options, SearchRequestBuilder requestBuilder) { Collection<String> uuids = query.projectUuids(); if (!uuids.isEmpty() && options.getFacets().isEmpty()) { requestBuilder.setRouting(uuids.stream().map(AuthorizationDoc::idOf).toArray(String...
[ "private", "static", "void", "configureRouting", "(", "IssueQuery", "query", ",", "SearchOptions", "options", ",", "SearchRequestBuilder", "requestBuilder", ")", "{", "Collection", "<", "String", ">", "uuids", "=", "query", ".", "projectUuids", "(", ")", ";", "i...
Optimization - do not send ES request to all shards when scope is restricted to a set of projects. Because project UUID is used for routing, the request can be sent to only the shards containing the specified projects. Note that sticky facets may involve all projects, so this optimization must be disabled when facets a...
[ "Optimization", "-", "do", "not", "send", "ES", "request", "to", "all", "shards", "when", "scope", "is", "restricted", "to", "a", "set", "of", "projects", ".", "Because", "project", "UUID", "is", "used", "for", "routing", "the", "request", "can", "be", "...
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/issue/index/IssueIndex.java#L319-L324
16,363
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/batch/bootstrap/ProjectDefinition.java
ProjectDefinition.setProperties
@Deprecated public ProjectDefinition setProperties(Properties properties) { for (Entry<Object, Object> entry : properties.entrySet()) { this.properties.put(entry.getKey().toString(), entry.getValue().toString()); } return this; }
java
@Deprecated public ProjectDefinition setProperties(Properties properties) { for (Entry<Object, Object> entry : properties.entrySet()) { this.properties.put(entry.getKey().toString(), entry.getValue().toString()); } return this; }
[ "@", "Deprecated", "public", "ProjectDefinition", "setProperties", "(", "Properties", "properties", ")", "{", "for", "(", "Entry", "<", "Object", ",", "Object", ">", "entry", ":", "properties", ".", "entrySet", "(", ")", ")", "{", "this", ".", "properties", ...
Copies specified properties into this object. @since 2.12 @deprecated since 5.0 use {@link #setProperties(Map)}
[ "Copies", "specified", "properties", "into", "this", "object", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/batch/bootstrap/ProjectDefinition.java#L127-L133
16,364
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/organization/OrganizationUpdaterImpl.java
OrganizationUpdaterImpl.insertOwnersGroup
private GroupDto insertOwnersGroup(DbSession dbSession, OrganizationDto organization) { GroupDto group = dbClient.groupDao().insert(dbSession, new GroupDto() .setOrganizationUuid(organization.getUuid()) .setName(OWNERS_GROUP_NAME) .setDescription(format(OWNERS_GROUP_DESCRIPTION_PATTERN, organizati...
java
private GroupDto insertOwnersGroup(DbSession dbSession, OrganizationDto organization) { GroupDto group = dbClient.groupDao().insert(dbSession, new GroupDto() .setOrganizationUuid(organization.getUuid()) .setName(OWNERS_GROUP_NAME) .setDescription(format(OWNERS_GROUP_DESCRIPTION_PATTERN, organizati...
[ "private", "GroupDto", "insertOwnersGroup", "(", "DbSession", "dbSession", ",", "OrganizationDto", "organization", ")", "{", "GroupDto", "group", "=", "dbClient", ".", "groupDao", "(", ")", ".", "insert", "(", "dbSession", ",", "new", "GroupDto", "(", ")", "."...
Owners group has an hard coded name, a description based on the organization's name and has all global permissions.
[ "Owners", "group", "has", "an", "hard", "coded", "name", "a", "description", "based", "on", "the", "organization", "s", "name", "and", "has", "all", "global", "permissions", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/organization/OrganizationUpdaterImpl.java#L322-L329
16,365
SonarSource/sonarqube
server/sonar-server/src/main/java/org/sonar/server/plugins/PluginDownloader.java
PluginDownloader.start
@Override public void start() { try { forceMkdir(downloadDir); for (File tempFile : listTempFile(this.downloadDir)) { deleteQuietly(tempFile); } } catch (IOException e) { throw new IllegalStateException("Fail to create the directory: " + downloadDir, e); } }
java
@Override public void start() { try { forceMkdir(downloadDir); for (File tempFile : listTempFile(this.downloadDir)) { deleteQuietly(tempFile); } } catch (IOException e) { throw new IllegalStateException("Fail to create the directory: " + downloadDir, e); } }
[ "@", "Override", "public", "void", "start", "(", ")", "{", "try", "{", "forceMkdir", "(", "downloadDir", ")", ";", "for", "(", "File", "tempFile", ":", "listTempFile", "(", "this", ".", "downloadDir", ")", ")", "{", "deleteQuietly", "(", "tempFile", ")",...
Deletes the temporary files remaining from previous downloads
[ "Deletes", "the", "temporary", "files", "remaining", "from", "previous", "downloads" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server/src/main/java/org/sonar/server/plugins/PluginDownloader.java#L74-L84
16,366
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/config/Settings.java
Settings.getDefinition
public Optional<PropertyDefinition> getDefinition(String key) { return Optional.ofNullable(definitions.get(key)); }
java
public Optional<PropertyDefinition> getDefinition(String key) { return Optional.ofNullable(definitions.get(key)); }
[ "public", "Optional", "<", "PropertyDefinition", ">", "getDefinition", "(", "String", "key", ")", "{", "return", "Optional", ".", "ofNullable", "(", "definitions", ".", "get", "(", "key", ")", ")", ";", "}" ]
The definition related to the specified property. It may be empty. @since 6.1
[ "The", "definition", "related", "to", "the", "specified", "property", ".", "It", "may", "be", "empty", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/config/Settings.java#L111-L113
16,367
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/config/Settings.java
Settings.getStringLines
public String[] getStringLines(String key) { String value = getString(key); if (StringUtils.isEmpty(value)) { return new String[0]; } return value.split("\r?\n|\r", -1); }
java
public String[] getStringLines(String key) { String value = getString(key); if (StringUtils.isEmpty(value)) { return new String[0]; } return value.split("\r?\n|\r", -1); }
[ "public", "String", "[", "]", "getStringLines", "(", "String", "key", ")", "{", "String", "value", "=", "getString", "(", "key", ")", ";", "if", "(", "StringUtils", ".", "isEmpty", "(", "value", ")", ")", "{", "return", "new", "String", "[", "0", "]"...
Value is split by carriage returns. @return non-null array of lines. The line termination characters are excluded. @since 3.2
[ "Value", "is", "split", "by", "carriage", "returns", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/config/Settings.java#L297-L303
16,368
SonarSource/sonarqube
sonar-plugin-api/src/main/java/org/sonar/api/config/Settings.java
Settings.getStringArrayBySeparator
public String[] getStringArrayBySeparator(String key, String separator) { String value = getString(key); if (value != null) { String[] strings = StringUtils.splitByWholeSeparator(value, separator); String[] result = new String[strings.length]; for (int index = 0; index < strings.length; index+...
java
public String[] getStringArrayBySeparator(String key, String separator) { String value = getString(key); if (value != null) { String[] strings = StringUtils.splitByWholeSeparator(value, separator); String[] result = new String[strings.length]; for (int index = 0; index < strings.length; index+...
[ "public", "String", "[", "]", "getStringArrayBySeparator", "(", "String", "key", ",", "String", "separator", ")", "{", "String", "value", "=", "getString", "(", "key", ")", ";", "if", "(", "value", "!=", "null", ")", "{", "String", "[", "]", "strings", ...
Value is split and trimmed.
[ "Value", "is", "split", "and", "trimmed", "." ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/sonar-plugin-api/src/main/java/org/sonar/api/config/Settings.java#L308-L319
16,369
SonarSource/sonarqube
server/sonar-server-common/src/main/java/org/sonar/server/notification/DefaultNotificationManager.java
DefaultNotificationManager.getFromQueue
public <T extends Notification> T getFromQueue() { int batchSize = 1; List<NotificationQueueDto> notificationDtos = dbClient.notificationQueueDao().selectOldest(batchSize); if (notificationDtos.isEmpty()) { return null; } dbClient.notificationQueueDao().delete(notificationDtos); return co...
java
public <T extends Notification> T getFromQueue() { int batchSize = 1; List<NotificationQueueDto> notificationDtos = dbClient.notificationQueueDao().selectOldest(batchSize); if (notificationDtos.isEmpty()) { return null; } dbClient.notificationQueueDao().delete(notificationDtos); return co...
[ "public", "<", "T", "extends", "Notification", ">", "T", "getFromQueue", "(", ")", "{", "int", "batchSize", "=", "1", ";", "List", "<", "NotificationQueueDto", ">", "notificationDtos", "=", "dbClient", ".", "notificationQueueDao", "(", ")", ".", "selectOldest"...
Give the notification queue so that it can be processed
[ "Give", "the", "notification", "queue", "so", "that", "it", "can", "be", "processed" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-server-common/src/main/java/org/sonar/server/notification/DefaultNotificationManager.java#L85-L94
16,370
SonarSource/sonarqube
server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeActivityDao.java
CeActivityDao.selectByQuery
public List<CeActivityDto> selectByQuery(DbSession dbSession, CeTaskQuery query, Pagination pagination) { if (query.isShortCircuitedByMainComponentUuids()) { return Collections.emptyList(); } return mapper(dbSession).selectByQuery(query, pagination); }
java
public List<CeActivityDto> selectByQuery(DbSession dbSession, CeTaskQuery query, Pagination pagination) { if (query.isShortCircuitedByMainComponentUuids()) { return Collections.emptyList(); } return mapper(dbSession).selectByQuery(query, pagination); }
[ "public", "List", "<", "CeActivityDto", ">", "selectByQuery", "(", "DbSession", "dbSession", ",", "CeTaskQuery", "query", ",", "Pagination", "pagination", ")", "{", "if", "(", "query", ".", "isShortCircuitedByMainComponentUuids", "(", ")", ")", "{", "return", "C...
Ordered by id desc -> newest to oldest
[ "Ordered", "by", "id", "desc", "-", ">", "newest", "to", "oldest" ]
2fffa4c2f79ae3714844d7742796e82822b6a98a
https://github.com/SonarSource/sonarqube/blob/2fffa4c2f79ae3714844d7742796e82822b6a98a/server/sonar-db-dao/src/main/java/org/sonar/db/ce/CeActivityDao.java#L71-L77
16,371
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/pvm/process/ProcessDefinitionImpl.java
ProcessDefinitionImpl.createProcessInstanceForInitial
public PvmProcessInstance createProcessInstanceForInitial(ActivityImpl initial) { ensureNotNull("Cannot start process instance, initial activity where the process instance should start is null", "initial", initial); PvmExecutionImpl processInstance = newProcessInstance(); processInstance.setProcessDefinit...
java
public PvmProcessInstance createProcessInstanceForInitial(ActivityImpl initial) { ensureNotNull("Cannot start process instance, initial activity where the process instance should start is null", "initial", initial); PvmExecutionImpl processInstance = newProcessInstance(); processInstance.setProcessDefinit...
[ "public", "PvmProcessInstance", "createProcessInstanceForInitial", "(", "ActivityImpl", "initial", ")", "{", "ensureNotNull", "(", "\"Cannot start process instance, initial activity where the process instance should start is null\"", ",", "\"initial\"", ",", "initial", ")", ";", "P...
creates a process instance using the provided activity as initial
[ "creates", "a", "process", "instance", "using", "the", "provided", "activity", "as", "initial" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/pvm/process/ProcessDefinitionImpl.java#L90-L105
16,372
camunda/camunda-bpm-platform
engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/HalRelation.java
HalRelation.build
public static HalRelation build(String relName, Class<?> resourceType, UriBuilder urlTemplate) { HalRelation relation = new HalRelation(); relation.relName = relName; relation.uriTemplate = urlTemplate; relation.resourceType = resourceType; return relation; }
java
public static HalRelation build(String relName, Class<?> resourceType, UriBuilder urlTemplate) { HalRelation relation = new HalRelation(); relation.relName = relName; relation.uriTemplate = urlTemplate; relation.resourceType = resourceType; return relation; }
[ "public", "static", "HalRelation", "build", "(", "String", "relName", ",", "Class", "<", "?", ">", "resourceType", ",", "UriBuilder", "urlTemplate", ")", "{", "HalRelation", "relation", "=", "new", "HalRelation", "(", ")", ";", "relation", ".", "relName", "=...
Build a relation to a resource. @param relName the name of the relation. @param resourceType the type of the resource @return the relation
[ "Build", "a", "relation", "to", "a", "resource", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/HalRelation.java#L43-L49
16,373
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/cmd/StartProcessInstanceAtActivitiesCmd.java
StartProcessInstanceAtActivitiesCmd.determineFirstActivity
protected ActivityImpl determineFirstActivity(ProcessDefinitionImpl processDefinition, ProcessInstanceModificationBuilderImpl modificationBuilder) { AbstractProcessInstanceModificationCommand firstInstruction = modificationBuilder.getModificationOperations().get(0); if (firstInstruction instanceof Abstra...
java
protected ActivityImpl determineFirstActivity(ProcessDefinitionImpl processDefinition, ProcessInstanceModificationBuilderImpl modificationBuilder) { AbstractProcessInstanceModificationCommand firstInstruction = modificationBuilder.getModificationOperations().get(0); if (firstInstruction instanceof Abstra...
[ "protected", "ActivityImpl", "determineFirstActivity", "(", "ProcessDefinitionImpl", "processDefinition", ",", "ProcessInstanceModificationBuilderImpl", "modificationBuilder", ")", "{", "AbstractProcessInstanceModificationCommand", "firstInstruction", "=", "modificationBuilder", ".", ...
get the activity that is started by the first instruction, if exists; return null if the first instruction is a start-transition instruction
[ "get", "the", "activity", "that", "is", "started", "by", "the", "first", "instruction", "if", "exists", ";", "return", "null", "if", "the", "first", "instruction", "is", "a", "start", "-", "transition", "instruction" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/cmd/StartProcessInstanceAtActivitiesCmd.java#L126-L149
16,374
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/bpmn/behavior/MultiInstanceActivityBehavior.java
MultiInstanceActivityBehavior.getInnerActivity
public ActivityImpl getInnerActivity(PvmActivity miBodyActivity) { for (PvmActivity activity : miBodyActivity.getActivities()) { ActivityImpl innerActivity = (ActivityImpl) activity; // note that miBody can contains also a compensation handler if (!innerActivity.isCompensationHandler()) { ...
java
public ActivityImpl getInnerActivity(PvmActivity miBodyActivity) { for (PvmActivity activity : miBodyActivity.getActivities()) { ActivityImpl innerActivity = (ActivityImpl) activity; // note that miBody can contains also a compensation handler if (!innerActivity.isCompensationHandler()) { ...
[ "public", "ActivityImpl", "getInnerActivity", "(", "PvmActivity", "miBodyActivity", ")", "{", "for", "(", "PvmActivity", "activity", ":", "miBodyActivity", ".", "getActivities", "(", ")", ")", "{", "ActivityImpl", "innerActivity", "=", "(", "ActivityImpl", ")", "a...
Get the inner activity of the multi instance execution. @param execution of multi instance activity @return inner activity
[ "Get", "the", "inner", "activity", "of", "the", "multi", "instance", "execution", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/bpmn/behavior/MultiInstanceActivityBehavior.java#L180-L189
16,375
camunda/camunda-bpm-platform
engine-spring/core/src/main/java/org/camunda/bpm/engine/spring/components/registry/ActivitiStateHandlerRegistry.java
ActivitiStateHandlerRegistry.registerActivitiStateHandler
public void registerActivitiStateHandler( ActivitiStateHandlerRegistration registration) { String regKey = registrationKey(registration.getProcessName(), registration.getStateName()); this.registrations.put(regKey, registration); }
java
public void registerActivitiStateHandler( ActivitiStateHandlerRegistration registration) { String regKey = registrationKey(registration.getProcessName(), registration.getStateName()); this.registrations.put(regKey, registration); }
[ "public", "void", "registerActivitiStateHandler", "(", "ActivitiStateHandlerRegistration", "registration", ")", "{", "String", "regKey", "=", "registrationKey", "(", "registration", ".", "getProcessName", "(", ")", ",", "registration", ".", "getStateName", "(", ")", "...
used at runtime to register state handlers as they are registered with the spring context @param registration the {@link org.camunda.bpm.engine.test.spring.components.registry.ActivitiStateHandlerRegistration}
[ "used", "at", "runtime", "to", "register", "state", "handlers", "as", "they", "are", "registered", "with", "the", "spring", "context" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine-spring/core/src/main/java/org/camunda/bpm/engine/spring/components/registry/ActivitiStateHandlerRegistry.java#L80-L85
16,376
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/DefaultPriorityProvider.java
DefaultPriorityProvider.evaluateValueProvider
protected Long evaluateValueProvider(ParameterValueProvider valueProvider, ExecutionEntity execution, String errorMessageHeading) { Object value; try { value = valueProvider.getValue(execution); } catch (ProcessEngineException e) { if (Context.getProcessEngineConfiguration().isEnableGracefulDe...
java
protected Long evaluateValueProvider(ParameterValueProvider valueProvider, ExecutionEntity execution, String errorMessageHeading) { Object value; try { value = valueProvider.getValue(execution); } catch (ProcessEngineException e) { if (Context.getProcessEngineConfiguration().isEnableGracefulDe...
[ "protected", "Long", "evaluateValueProvider", "(", "ParameterValueProvider", "valueProvider", ",", "ExecutionEntity", "execution", ",", "String", "errorMessageHeading", ")", "{", "Object", "value", ";", "try", "{", "value", "=", "valueProvider", ".", "getValue", "(", ...
Evaluates a given value provider with the given execution entity to determine the correct value. The error message heading is used for the error message if the validation fails because the value is no valid priority. @param valueProvider the provider which contains the value @param execution the execution entity @para...
[ "Evaluates", "a", "given", "value", "provider", "with", "the", "given", "execution", "entity", "to", "determine", "the", "correct", "value", ".", "The", "error", "message", "heading", "is", "used", "for", "the", "error", "message", "if", "the", "validation", ...
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/DefaultPriorityProvider.java#L73-L103
16,377
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/DefaultPriorityProvider.java
DefaultPriorityProvider.getProcessDefinedPriority
protected Long getProcessDefinedPriority(ProcessDefinitionImpl processDefinition, String propertyKey, ExecutionEntity execution, String errorMsgHead) { if (processDefinition != null) { ParameterValueProvider priorityProvider = (ParameterValueProvider) processDefinition.getProperty(propertyKey); if (prio...
java
protected Long getProcessDefinedPriority(ProcessDefinitionImpl processDefinition, String propertyKey, ExecutionEntity execution, String errorMsgHead) { if (processDefinition != null) { ParameterValueProvider priorityProvider = (ParameterValueProvider) processDefinition.getProperty(propertyKey); if (prio...
[ "protected", "Long", "getProcessDefinedPriority", "(", "ProcessDefinitionImpl", "processDefinition", ",", "String", "propertyKey", ",", "ExecutionEntity", "execution", ",", "String", "errorMsgHead", ")", "{", "if", "(", "processDefinition", "!=", "null", ")", "{", "Pa...
Returns the priority which is defined in the given process definition. The priority value is identified with the given propertyKey. Returns null if the process definition is null or no priority was defined. @param processDefinition the process definition that should contains the priority @param propertyKey the key whi...
[ "Returns", "the", "priority", "which", "is", "defined", "in", "the", "given", "process", "definition", ".", "The", "priority", "value", "is", "identified", "with", "the", "given", "propertyKey", ".", "Returns", "null", "if", "the", "process", "definition", "is...
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/DefaultPriorityProvider.java#L154-L162
16,378
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/AbstractDefinitionDeployer.java
AbstractDefinitionDeployer.getDiagramResourceForDefinition
protected String getDiagramResourceForDefinition(DeploymentEntity deployment, String resourceName, DefinitionEntity definition, Map<String, ResourceEntity> resources) { for (String diagramSuffix: getDiagramSuffixes()) { String definitionDiagramResource = getDefinitionDiagramResourceName(resourceName, definiti...
java
protected String getDiagramResourceForDefinition(DeploymentEntity deployment, String resourceName, DefinitionEntity definition, Map<String, ResourceEntity> resources) { for (String diagramSuffix: getDiagramSuffixes()) { String definitionDiagramResource = getDefinitionDiagramResourceName(resourceName, definiti...
[ "protected", "String", "getDiagramResourceForDefinition", "(", "DeploymentEntity", "deployment", ",", "String", "resourceName", ",", "DefinitionEntity", "definition", ",", "Map", "<", "String", ",", "ResourceEntity", ">", "resources", ")", "{", "for", "(", "String", ...
Returns the default name of the image resource for a certain definition. It will first look for an image resource which matches the definition specifically, before resorting to an image resource which matches the file containing the definition. Example: if the deployment contains a BPMN 2.0 xml resource called 'abc.b...
[ "Returns", "the", "default", "name", "of", "the", "image", "resource", "for", "a", "certain", "definition", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/AbstractDefinitionDeployer.java#L144-L156
16,379
camunda/camunda-bpm-platform
engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java
HalCachingLinkResolver.resolveLinks
public List<HalResource<?>> resolveLinks(String[] linkedIds, ProcessEngine processEngine) { Cache cache = getCache(); if (cache == null) { return resolveNotCachedLinks(linkedIds, processEngine); } else { ArrayList<String> notCachedLinkedIds = new ArrayList<String>(); List<HalResource<...
java
public List<HalResource<?>> resolveLinks(String[] linkedIds, ProcessEngine processEngine) { Cache cache = getCache(); if (cache == null) { return resolveNotCachedLinks(linkedIds, processEngine); } else { ArrayList<String> notCachedLinkedIds = new ArrayList<String>(); List<HalResource<...
[ "public", "List", "<", "HalResource", "<", "?", ">", ">", "resolveLinks", "(", "String", "[", "]", "linkedIds", ",", "ProcessEngine", "processEngine", ")", "{", "Cache", "cache", "=", "getCache", "(", ")", ";", "if", "(", "cache", "==", "null", ")", "{...
Resolve resources for linked ids, if configured uses a cache.
[ "Resolve", "resources", "for", "linked", "ids", "if", "configured", "uses", "a", "cache", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java#L35-L55
16,380
camunda/camunda-bpm-platform
engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java
HalCachingLinkResolver.sortResolvedResources
protected void sortResolvedResources(List<HalResource<?>> resolvedResources) { Comparator<HalResource<?>> comparator = getResourceComparator(); if (comparator != null) { Collections.sort(resolvedResources, comparator); } }
java
protected void sortResolvedResources(List<HalResource<?>> resolvedResources) { Comparator<HalResource<?>> comparator = getResourceComparator(); if (comparator != null) { Collections.sort(resolvedResources, comparator); } }
[ "protected", "void", "sortResolvedResources", "(", "List", "<", "HalResource", "<", "?", ">", ">", "resolvedResources", ")", "{", "Comparator", "<", "HalResource", "<", "?", ">", ">", "comparator", "=", "getResourceComparator", "(", ")", ";", "if", "(", "com...
Sort the resolved resources to ensure consistent order of resolved resources.
[ "Sort", "the", "resolved", "resources", "to", "ensure", "consistent", "order", "of", "resolved", "resources", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java#L60-L65
16,381
camunda/camunda-bpm-platform
engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java
HalCachingLinkResolver.resolveCachedLinks
protected List<HalResource<?>> resolveCachedLinks(String[] linkedIds, Cache cache, List<String> notCachedLinkedIds) { ArrayList<HalResource<?>> resolvedResources = new ArrayList<HalResource<?>>(); for (String linkedId : linkedIds) { HalResource<?> resource = (HalResource<?>) cache.get(linkedId); if...
java
protected List<HalResource<?>> resolveCachedLinks(String[] linkedIds, Cache cache, List<String> notCachedLinkedIds) { ArrayList<HalResource<?>> resolvedResources = new ArrayList<HalResource<?>>(); for (String linkedId : linkedIds) { HalResource<?> resource = (HalResource<?>) cache.get(linkedId); if...
[ "protected", "List", "<", "HalResource", "<", "?", ">", ">", "resolveCachedLinks", "(", "String", "[", "]", "linkedIds", ",", "Cache", "cache", ",", "List", "<", "String", ">", "notCachedLinkedIds", ")", "{", "ArrayList", "<", "HalResource", "<", "?", ">",...
Returns a list with all resources which are cached. @param linkedIds the ids to resolve @param cache the cache to use @param notCachedLinkedIds a list with ids which are not found in the cache @return the cached resources
[ "Returns", "a", "list", "with", "all", "resources", "which", "are", "cached", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java#L82-L96
16,382
camunda/camunda-bpm-platform
engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java
HalCachingLinkResolver.putIntoCache
protected void putIntoCache(List<HalResource<?>> notCachedResources) { Cache cache = getCache(); for (HalResource<?> notCachedResource : notCachedResources) { cache.put(getResourceId(notCachedResource), notCachedResource); } }
java
protected void putIntoCache(List<HalResource<?>> notCachedResources) { Cache cache = getCache(); for (HalResource<?> notCachedResource : notCachedResources) { cache.put(getResourceId(notCachedResource), notCachedResource); } }
[ "protected", "void", "putIntoCache", "(", "List", "<", "HalResource", "<", "?", ">", ">", "notCachedResources", ")", "{", "Cache", "cache", "=", "getCache", "(", ")", ";", "for", "(", "HalResource", "<", "?", ">", "notCachedResource", ":", "notCachedResource...
Put a resource into the cache.
[ "Put", "a", "resource", "into", "the", "cache", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine-rest/engine-rest/src/main/java/org/camunda/bpm/engine/rest/hal/cache/HalCachingLinkResolver.java#L101-L106
16,383
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/persistence/entity/ProcessDefinitionEntity.java
ProcessDefinitionEntity.updateModifiableFieldsFromEntity
@Override public void updateModifiableFieldsFromEntity(ProcessDefinitionEntity updatingProcessDefinition) { if (this.key.equals(updatingProcessDefinition.key) && this.deploymentId.equals(updatingProcessDefinition.deploymentId)) { // TODO: add a guard once the mismatch between revisions in deployment cache a...
java
@Override public void updateModifiableFieldsFromEntity(ProcessDefinitionEntity updatingProcessDefinition) { if (this.key.equals(updatingProcessDefinition.key) && this.deploymentId.equals(updatingProcessDefinition.deploymentId)) { // TODO: add a guard once the mismatch between revisions in deployment cache a...
[ "@", "Override", "public", "void", "updateModifiableFieldsFromEntity", "(", "ProcessDefinitionEntity", "updatingProcessDefinition", ")", "{", "if", "(", "this", ".", "key", ".", "equals", "(", "updatingProcessDefinition", ".", "key", ")", "&&", "this", ".", "deploym...
Updates all modifiable fields from another process definition entity. @param updatingProcessDefinition
[ "Updates", "all", "modifiable", "fields", "from", "another", "process", "definition", "entity", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/persistence/entity/ProcessDefinitionEntity.java#L200-L211
16,384
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/util/ScriptUtil.java
ScriptUtil.isDynamicScriptExpression
public static boolean isDynamicScriptExpression(String language, String value) { return StringUtil.isExpression(value) && (language != null && !JuelScriptEngineFactory.names.contains(language.toLowerCase())); }
java
public static boolean isDynamicScriptExpression(String language, String value) { return StringUtil.isExpression(value) && (language != null && !JuelScriptEngineFactory.names.contains(language.toLowerCase())); }
[ "public", "static", "boolean", "isDynamicScriptExpression", "(", "String", "language", ",", "String", "value", ")", "{", "return", "StringUtil", ".", "isExpression", "(", "value", ")", "&&", "(", "language", "!=", "null", "&&", "!", "JuelScriptEngineFactory", "....
Checks if the value is an expression for a dynamic script source or resource. @param language the language of the script @param value the value to check @return true if the value is an expression for a dynamic script source/resource, otherwise false
[ "Checks", "if", "the", "value", "is", "an", "expression", "for", "a", "dynamic", "script", "source", "or", "resource", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/util/ScriptUtil.java#L192-L194
16,385
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/util/ScriptUtil.java
ScriptUtil.getScriptFactory
public static ScriptFactory getScriptFactory() { ProcessEngineConfigurationImpl processEngineConfiguration = Context.getProcessEngineConfiguration(); if (processEngineConfiguration != null) { return processEngineConfiguration.getScriptFactory(); } else { return new ScriptFactory(); } }
java
public static ScriptFactory getScriptFactory() { ProcessEngineConfigurationImpl processEngineConfiguration = Context.getProcessEngineConfiguration(); if (processEngineConfiguration != null) { return processEngineConfiguration.getScriptFactory(); } else { return new ScriptFactory(); } }
[ "public", "static", "ScriptFactory", "getScriptFactory", "(", ")", "{", "ProcessEngineConfigurationImpl", "processEngineConfiguration", "=", "Context", ".", "getProcessEngineConfiguration", "(", ")", ";", "if", "(", "processEngineConfiguration", "!=", "null", ")", "{", ...
Returns the configured script factory in the context or a new one.
[ "Returns", "the", "configured", "script", "factory", "in", "the", "context", "or", "a", "new", "one", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/util/ScriptUtil.java#L199-L207
16,386
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/cmd/DeployCmd.java
DeployCmd.resumePreviousByProcessDefinitionKey
protected Set<String> resumePreviousByProcessDefinitionKey(CommandContext commandContext, DeploymentEntity deployment, Set<String> processKeysToRegisterFor) { Set<String> processDefinitionKeys = new HashSet<String>(processKeysToRegisterFor); List<? extends ProcessDefinition> deployedProcesses = getDeployedProc...
java
protected Set<String> resumePreviousByProcessDefinitionKey(CommandContext commandContext, DeploymentEntity deployment, Set<String> processKeysToRegisterFor) { Set<String> processDefinitionKeys = new HashSet<String>(processKeysToRegisterFor); List<? extends ProcessDefinition> deployedProcesses = getDeployedProc...
[ "protected", "Set", "<", "String", ">", "resumePreviousByProcessDefinitionKey", "(", "CommandContext", "commandContext", ",", "DeploymentEntity", "deployment", ",", "Set", "<", "String", ">", "processKeysToRegisterFor", ")", "{", "Set", "<", "String", ">", "processDef...
Searches in previous deployments for the same processes and retrieves the deployment ids. @param commandContext @param deployment the current deployment @param processKeysToRegisterFor the process keys this process application wants to register @param deployment the set where to add further deployments this process ap...
[ "Searches", "in", "previous", "deployments", "for", "the", "same", "processes", "and", "retrieves", "the", "deployment", "ids", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/cmd/DeployCmd.java#L552-L563
16,387
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/cmd/DeployCmd.java
DeployCmd.resumePreviousByDeploymentName
protected Set<String> resumePreviousByDeploymentName(CommandContext commandContext, DeploymentEntity deployment) { List<Deployment> previousDeployments = new DeploymentQueryImpl().deploymentName(deployment.getName()).list(); Set<String> deploymentIds = new HashSet<String>(previousDeployments.size()); for (D...
java
protected Set<String> resumePreviousByDeploymentName(CommandContext commandContext, DeploymentEntity deployment) { List<Deployment> previousDeployments = new DeploymentQueryImpl().deploymentName(deployment.getName()).list(); Set<String> deploymentIds = new HashSet<String>(previousDeployments.size()); for (D...
[ "protected", "Set", "<", "String", ">", "resumePreviousByDeploymentName", "(", "CommandContext", "commandContext", ",", "DeploymentEntity", "deployment", ")", "{", "List", "<", "Deployment", ">", "previousDeployments", "=", "new", "DeploymentQueryImpl", "(", ")", ".",...
Searches for previous deployments with the same name. @param commandContext @param deployment the current deployment @return a set of deployment ids
[ "Searches", "for", "previous", "deployments", "with", "the", "same", "name", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/cmd/DeployCmd.java#L571-L578
16,388
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/cmmn/execution/CmmnExecution.java
CmmnExecution.getSatisfiedSentries
protected List<String> getSatisfiedSentries(List<String> sentryIds) { List<String> result = new ArrayList<String>(); if (sentryIds != null) { for (String sentryId : sentryIds) { if (isSentrySatisfied(sentryId)) { result.add(sentryId); } } } return result; }
java
protected List<String> getSatisfiedSentries(List<String> sentryIds) { List<String> result = new ArrayList<String>(); if (sentryIds != null) { for (String sentryId : sentryIds) { if (isSentrySatisfied(sentryId)) { result.add(sentryId); } } } return result; }
[ "protected", "List", "<", "String", ">", "getSatisfiedSentries", "(", "List", "<", "String", ">", "sentryIds", ")", "{", "List", "<", "String", ">", "result", "=", "new", "ArrayList", "<", "String", ">", "(", ")", ";", "if", "(", "sentryIds", "!=", "nu...
Checks for each given sentry id whether the corresponding sentry is satisfied.
[ "Checks", "for", "each", "given", "sentry", "id", "whether", "the", "corresponding", "sentry", "is", "satisfied", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/cmmn/execution/CmmnExecution.java#L497-L511
16,389
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/cmmn/execution/CmmnExecution.java
CmmnExecution.getSatisfiedSentriesInExecutionTree
protected List<String> getSatisfiedSentriesInExecutionTree(List<String> sentryIds, Map<String, List<CmmnSentryPart>> allSentries) { List<String> result = new ArrayList<String>(); if (sentryIds != null) { for (String sentryId : sentryIds) { List<CmmnSentryPart> sentryParts = allSentries.get(sentr...
java
protected List<String> getSatisfiedSentriesInExecutionTree(List<String> sentryIds, Map<String, List<CmmnSentryPart>> allSentries) { List<String> result = new ArrayList<String>(); if (sentryIds != null) { for (String sentryId : sentryIds) { List<CmmnSentryPart> sentryParts = allSentries.get(sentr...
[ "protected", "List", "<", "String", ">", "getSatisfiedSentriesInExecutionTree", "(", "List", "<", "String", ">", "sentryIds", ",", "Map", "<", "String", ",", "List", "<", "CmmnSentryPart", ">", ">", "allSentries", ")", "{", "List", "<", "String", ">", "resul...
Checks for each given sentry id in the execution tree whether the corresponding sentry is satisfied.
[ "Checks", "for", "each", "given", "sentry", "id", "in", "the", "execution", "tree", "whether", "the", "corresponding", "sentry", "is", "satisfied", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/cmmn/execution/CmmnExecution.java#L517-L531
16,390
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/javax/el/ArrayELResolver.java
ArrayELResolver.getValue
@Override public Object getValue(ELContext context, Object base, Object property) { if (context == null) { throw new NullPointerException("context is null"); } Object result = null; if (isResolvable(base)) { int index = toIndex(null, property); result = index < 0 || index >= Array.getLength(base) ? nu...
java
@Override public Object getValue(ELContext context, Object base, Object property) { if (context == null) { throw new NullPointerException("context is null"); } Object result = null; if (isResolvable(base)) { int index = toIndex(null, property); result = index < 0 || index >= Array.getLength(base) ? nu...
[ "@", "Override", "public", "Object", "getValue", "(", "ELContext", "context", ",", "Object", "base", ",", "Object", "property", ")", "{", "if", "(", "context", "==", "null", ")", "{", "throw", "new", "NullPointerException", "(", "\"context is null\"", ")", "...
If the base object is a Java language array, returns the value at the given index. The index is specified by the property argument, and coerced into an integer. If the coercion could not be performed, an IllegalArgumentException is thrown. If the index is out of bounds, null is returned. If the base is a Java language ...
[ "If", "the", "base", "object", "is", "a", "Java", "language", "array", "returns", "the", "value", "at", "the", "given", "index", ".", "The", "index", "is", "specified", "by", "the", "property", "argument", "and", "coerced", "into", "an", "integer", ".", ...
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/javax/el/ArrayELResolver.java#L155-L167
16,391
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/javax/el/ArrayELResolver.java
ArrayELResolver.setValue
@Override public void setValue(ELContext context, Object base, Object property, Object value) { if (context == null) { throw new NullPointerException("context is null"); } if (isResolvable(base)) { if (readOnly) { throw new PropertyNotWritableException("resolver is read-only"); } Array.set(base, ...
java
@Override public void setValue(ELContext context, Object base, Object property, Object value) { if (context == null) { throw new NullPointerException("context is null"); } if (isResolvable(base)) { if (readOnly) { throw new PropertyNotWritableException("resolver is read-only"); } Array.set(base, ...
[ "@", "Override", "public", "void", "setValue", "(", "ELContext", "context", ",", "Object", "base", ",", "Object", "property", ",", "Object", "value", ")", "{", "if", "(", "context", "==", "null", ")", "{", "throw", "new", "NullPointerException", "(", "\"co...
If the base object is a Java language array, attempts to set the value at the given index with the given value. The index is specified by the property argument, and coerced into an integer. If the coercion could not be performed, an IllegalArgumentException is thrown. If the index is out of bounds, a PropertyNotFoundEx...
[ "If", "the", "base", "object", "is", "a", "Java", "language", "array", "attempts", "to", "set", "the", "value", "at", "the", "given", "index", "with", "the", "given", "value", ".", "The", "index", "is", "specified", "by", "the", "property", "argument", "...
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/javax/el/ArrayELResolver.java#L245-L257
16,392
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/util/ParseUtil.java
ParseUtil.parseHistoryTimeToLive
public static Integer parseHistoryTimeToLive(String historyTimeToLive) { Integer timeToLive = null; if (historyTimeToLive != null && !historyTimeToLive.isEmpty()) { Matcher matISO = REGEX_TTL_ISO.matcher(historyTimeToLive); if (matISO.find()) { historyTimeToLive = matISO.group(1); } ...
java
public static Integer parseHistoryTimeToLive(String historyTimeToLive) { Integer timeToLive = null; if (historyTimeToLive != null && !historyTimeToLive.isEmpty()) { Matcher matISO = REGEX_TTL_ISO.matcher(historyTimeToLive); if (matISO.find()) { historyTimeToLive = matISO.group(1); } ...
[ "public", "static", "Integer", "parseHistoryTimeToLive", "(", "String", "historyTimeToLive", ")", "{", "Integer", "timeToLive", "=", "null", ";", "if", "(", "historyTimeToLive", "!=", "null", "&&", "!", "historyTimeToLive", ".", "isEmpty", "(", ")", ")", "{", ...
Parse History Time To Live in ISO-8601 format to integer and set into the given entity @param historyTimeToLive
[ "Parse", "History", "Time", "To", "Live", "in", "ISO", "-", "8601", "format", "to", "integer", "and", "set", "into", "the", "given", "entity" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/util/ParseUtil.java#L42-L58
16,393
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/form/validator/FormValidators.java
FormValidators.createValidator
public FormFieldValidator createValidator(Element constraint, BpmnParse bpmnParse, ExpressionManager expressionManager) { String name = constraint.attribute("name"); String config = constraint.attribute("config"); if("validator".equals(name)) { // custom validators if(config == null || confi...
java
public FormFieldValidator createValidator(Element constraint, BpmnParse bpmnParse, ExpressionManager expressionManager) { String name = constraint.attribute("name"); String config = constraint.attribute("config"); if("validator".equals(name)) { // custom validators if(config == null || confi...
[ "public", "FormFieldValidator", "createValidator", "(", "Element", "constraint", ",", "BpmnParse", "bpmnParse", ",", "ExpressionManager", "expressionManager", ")", "{", "String", "name", "=", "constraint", ".", "attribute", "(", "\"name\"", ")", ";", "String", "conf...
factory method for creating validator instances
[ "factory", "method", "for", "creating", "validator", "instances" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/form/validator/FormValidators.java#L47-L91
16,394
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/application/impl/EmbeddedProcessApplication.java
EmbeddedProcessApplication.execute
public <T> T execute(Callable<T> callable) throws ProcessApplicationExecutionException { try { return callable.call(); } catch (Exception e) { throw LOG.processApplicationExecutionException(e); } }
java
public <T> T execute(Callable<T> callable) throws ProcessApplicationExecutionException { try { return callable.call(); } catch (Exception e) { throw LOG.processApplicationExecutionException(e); } }
[ "public", "<", "T", ">", "T", "execute", "(", "Callable", "<", "T", ">", "callable", ")", "throws", "ProcessApplicationExecutionException", "{", "try", "{", "return", "callable", ".", "call", "(", ")", ";", "}", "catch", "(", "Exception", "e", ")", "{", ...
Since the process engine is loaded by the same classloader as the process application, nothing needs to be done.
[ "Since", "the", "process", "engine", "is", "loaded", "by", "the", "same", "classloader", "as", "the", "process", "application", "nothing", "needs", "to", "be", "done", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/application/impl/EmbeddedProcessApplication.java#L53-L60
16,395
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java
PvmExecutionImpl.startWithoutExecuting
public void startWithoutExecuting(Map<String, Object> variables) { initialize(); initializeTimerDeclarations(); fireHistoricProcessStartEvent(); performOperation(PvmAtomicOperation.FIRE_PROCESS_START); setActivity(null); setActivityInstanceId(getId()); // set variables setVariables(var...
java
public void startWithoutExecuting(Map<String, Object> variables) { initialize(); initializeTimerDeclarations(); fireHistoricProcessStartEvent(); performOperation(PvmAtomicOperation.FIRE_PROCESS_START); setActivity(null); setActivityInstanceId(getId()); // set variables setVariables(var...
[ "public", "void", "startWithoutExecuting", "(", "Map", "<", "String", ",", "Object", ">", "variables", ")", "{", "initialize", "(", ")", ";", "initializeTimerDeclarations", "(", ")", ";", "fireHistoricProcessStartEvent", "(", ")", ";", "performOperation", "(", "...
perform starting behavior but don't execute the initial activity @param variables the variables which are used for the start
[ "perform", "starting", "behavior", "but", "don", "t", "execute", "the", "initial", "activity" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java#L255-L266
16,396
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java
PvmExecutionImpl.end
@Override public void end(boolean completeScope) { setCompleteScope(completeScope); isActive = false; isEnded = true; if (hasReplacedParent()) { getParent().replacedBy = null; } performOperation(PvmAtomicOperation.ACTIVITY_NOTIFY_LISTENER_END); }
java
@Override public void end(boolean completeScope) { setCompleteScope(completeScope); isActive = false; isEnded = true; if (hasReplacedParent()) { getParent().replacedBy = null; } performOperation(PvmAtomicOperation.ACTIVITY_NOTIFY_LISTENER_END); }
[ "@", "Override", "public", "void", "end", "(", "boolean", "completeScope", ")", "{", "setCompleteScope", "(", "completeScope", ")", ";", "isActive", "=", "false", ";", "isEnded", "=", "true", ";", "if", "(", "hasReplacedParent", "(", ")", ")", "{", "getPar...
Ends an execution. Invokes end listeners for the current activity and notifies the flow scope execution of this happening which may result in the flow scope ending. @param completeScope true if ending the execution contributes to completing the BPMN 2.0 scope
[ "Ends", "an", "execution", ".", "Invokes", "end", "listeners", "for", "the", "current", "activity", "and", "notifies", "the", "flow", "scope", "execution", "of", "this", "happening", "which", "may", "result", "in", "the", "flow", "scope", "ending", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java#L340-L354
16,397
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java
PvmExecutionImpl.executeActivitiesConcurrent
public void executeActivitiesConcurrent(List<PvmActivity> activityStack, PvmActivity targetActivity, PvmTransition targetTransition, Map<String, Object> variables, Map<String, Object> localVariables, boolean skipCustomListeners, boolean...
java
public void executeActivitiesConcurrent(List<PvmActivity> activityStack, PvmActivity targetActivity, PvmTransition targetTransition, Map<String, Object> variables, Map<String, Object> localVariables, boolean skipCustomListeners, boolean...
[ "public", "void", "executeActivitiesConcurrent", "(", "List", "<", "PvmActivity", ">", "activityStack", ",", "PvmActivity", "targetActivity", ",", "PvmTransition", "targetTransition", ",", "Map", "<", "String", ",", "Object", ">", "variables", ",", "Map", "<", "St...
Instantiates the given activity stack under this execution. Sets the variables for the execution responsible to execute the most deeply nested activity. @param activityStack The most deeply nested activity is the last element in the list
[ "Instantiates", "the", "given", "activity", "stack", "under", "this", "execution", ".", "Sets", "the", "variables", "for", "the", "execution", "responsible", "to", "execute", "the", "most", "deeply", "nested", "activity", "." ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java#L812-L836
16,398
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java
PvmExecutionImpl.instantiateScopes
public Map<PvmActivity, PvmExecutionImpl> instantiateScopes(List<PvmActivity> activityStack, boolean skipCustomListeners, boolean skipIoMappings) { if (activityStack.isEmpty()) { return...
java
public Map<PvmActivity, PvmExecutionImpl> instantiateScopes(List<PvmActivity> activityStack, boolean skipCustomListeners, boolean skipIoMappings) { if (activityStack.isEmpty()) { return...
[ "public", "Map", "<", "PvmActivity", ",", "PvmExecutionImpl", ">", "instantiateScopes", "(", "List", "<", "PvmActivity", ">", "activityStack", ",", "boolean", "skipCustomListeners", ",", "boolean", "skipIoMappings", ")", "{", "if", "(", "activityStack", ".", "isEm...
Instantiates the given set of activities and returns the execution for the bottom-most activity
[ "Instantiates", "the", "given", "set", "of", "activities", "and", "returns", "the", "execution", "for", "the", "bottom", "-", "most", "activity" ]
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java#L841-L875
16,399
camunda/camunda-bpm-platform
engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java
PvmExecutionImpl.executeActivities
public void executeActivities(List<PvmActivity> activityStack, PvmActivity targetActivity, PvmTransition targetTransition, Map<String, Object> variables, Map<String, Object> localVariables, boolean skipCustomListeners, boolean skipIoMappings) { this....
java
public void executeActivities(List<PvmActivity> activityStack, PvmActivity targetActivity, PvmTransition targetTransition, Map<String, Object> variables, Map<String, Object> localVariables, boolean skipCustomListeners, boolean skipIoMappings) { this....
[ "public", "void", "executeActivities", "(", "List", "<", "PvmActivity", ">", "activityStack", ",", "PvmActivity", "targetActivity", ",", "PvmTransition", "targetTransition", ",", "Map", "<", "String", ",", "Object", ">", "variables", ",", "Map", "<", "String", "...
Instantiates the given activity stack. Uses this execution to execute the highest activity in the stack. Sets the variables for the execution responsible to execute the most deeply nested activity. @param activityStack The most deeply nested activity is the last element in the list
[ "Instantiates", "the", "given", "activity", "stack", ".", "Uses", "this", "execution", "to", "execute", "the", "highest", "activity", "in", "the", "stack", ".", "Sets", "the", "variables", "for", "the", "execution", "responsible", "to", "execute", "the", "most...
1a464fc887ef3760e53d6f91b9e5b871a0d77cc0
https://github.com/camunda/camunda-bpm-platform/blob/1a464fc887ef3760e53d6f91b9e5b871a0d77cc0/engine/src/main/java/org/camunda/bpm/engine/impl/pvm/runtime/PvmExecutionImpl.java#L885-L919