type stringclasses 7
values | content stringlengths 4 9.55k | repo stringlengths 7 96 | path stringlengths 4 178 | language stringclasses 1
value |
|---|---|---|---|---|
ArrowFunction |
(publicKey: Maybe<string>) => {
const intes = useConvInteractions(publicKey)
return Object.values(intes) as berty.messenger.v1.IInteraction[]
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(publicKey: Maybe<string>) => {
const intes = useConvInteractionsList(publicKey)
return intes.sort((a, b) => pbDateToNum(a.sentDate) - pbDateToNum(b.sentDate))
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(a, b) => pbDateToNum(a.sentDate) - pbDateToNum(b.sentDate) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(cid: Maybe<string>, convPk: Maybe<string>) => {
const intes = useConvInteractions(convPk)
return intes && intes[cid as string]
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
return useConversationList().length
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(publicKey: Maybe<string>) => {
const ctx = useMsgrContext()
return ctx.members[publicKey as string] || {}
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(publicKey: Maybe<string>) => {
const members = useConvMembers(publicKey)
return Object.values(members) as berty.messenger.v1.IMember[]
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
return ctx.persistentOptions || {}
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
return useCallback(() => ctx.dispatch({ type: MessengerActions.Restart }), [ctx])
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => ctx.dispatch({ type: MessengerActions.Restart }) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
return useCallback(() => ctx.dispatch({ type: MessengerActions.SetStateDeleting }), [ctx])
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => ctx.dispatch({ type: MessengerActions.SetStateDeleting }) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
return useCallback(
(accountID) => ctx.dispatch({ type: MessengerActions.SetNextAccount, payload: accountID }),
[ctx],
)
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(accountID) => ctx.dispatch({ type: MessengerActions.SetNextAccount, payload: accountID }) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
const prevFakeCount: number = Object.values(ctx.contacts).reduce(
(r, c) => ((c as any).fake ? r + 1 : r),
0,
)
return (length = 10) => {
const payload = fakeContacts(length, prevFakeCount)
ctx.dispatch({
type: MessengerActions.AddFakeData,
payload,
})
}
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(r, c) => ((c as any).fake ? r + 1 : r) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(length = 10) => {
const payload = fakeContacts(length, prevFakeCount)
ctx.dispatch({
type: MessengerActions.AddFakeData,
payload,
})
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
const prevFakeCount = Object.values(ctx.conversations).reduce(
(r, c) =>
(c as any).fake && c?.type === messengerpb.Conversation.Type.MultiMemberType ? r + 1 : r,
0,
)
return (length = 10) => {
const payload = fakeMultiMemberConversations(length, prevFakeCount)
ctx.d... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(r, c) =>
(c as any).fake && c?.type === messengerpb.Conversation.Type.MultiMemberType ? r + 1 : r | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(length = 10) => {
const payload = fakeMultiMemberConversations(length, prevFakeCount)
ctx.dispatch({
type: MessengerActions.AddFakeData,
payload,
})
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
const fakeConversationList = useConversationList().filter((c) => (c as any).fake === true)
const fakeMembersListList = fakeConversationList.map((conv) =>
Object.values(ctx.members[conv.publicKey || ''] || {}).filter((member: any) => member.fake),
)
console.log('fakeConvCount... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(c) => (c as any).fake === true | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(conv) =>
Object.values(ctx.members[conv.publicKey || ''] || {}).filter((member: any) => member.fake) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(member: any) => member.fake | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(r, fakeConv) =>
Object.values(ctx.interactions[fakeConv.publicKey || ''] || {}).reduce(
(r2, inte) => ((inte as any).fake ? r2 + 1 : r2),
r,
) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(r2, inte) => ((inte as any).fake ? r2 + 1 : r2) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(length = 10) => {
ctx.dispatch({
type: MessengerActions.AddFakeData,
payload: {
interactions: fakeMessages(
length,
fakeConversationList,
fakeMembersListList,
prevFakeCount,
),
},
})
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
return () =>
ctx.dispatch({
type: MessengerActions.DeleteFakeData,
})
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() =>
ctx.dispatch({
type: MessengerActions.DeleteFakeData,
}) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(
convPublicKey: Maybe<string>,
filterFunc: Maybe<SortedConvsFilter>,
) => {
let intes = useSortedConvInteractions(convPublicKey)
if (filterFunc) {
intes = intes.filter(filterFunc)
}
if (intes.length <= 0) {
return null
}
return intes[intes.length - 1]
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
const ctx = useMsgrContext()
return ctx.dispatch
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(inhibitor: Maybe<NotificationsInhibitor>) => {
const dispatch = useDispatch()
const navigation = useNavigation()
useMountEffect(() => {
if (!inhibitor) {
return
}
const inhibit = () =>
dispatch({ type: MessengerActions.AddNotificationInhibitor, payload: { inhibitor } })
const revert = () =>
dispa... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
if (!inhibitor) {
return
}
const inhibit = () =>
dispatch({ type: MessengerActions.AddNotificationInhibitor, payload: { inhibitor } })
const revert = () =>
dispatch({ type: MessengerActions.RemoveNotificationInhibitor, payload: { inhibitor } })
const unsubscribeBlur = navigation.addListene... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() =>
dispatch({ type: MessengerActions.AddNotificationInhibitor, payload: { inhibitor } }) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() =>
dispatch({ type: MessengerActions.RemoveNotificationInhibitor, payload: { inhibitor } }) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
unsubscribeFocus()
unsubscribeBlur()
revert()
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(publicKey: Maybe<string>, timeout: Maybe<number>) => {
// timeout is the duration (in ms) that the user must stay on the page to set messages as read
const navigation = useNavigation()
const ctx = useMsgrContext()
const conv = useConversation(publicKey)
const fake = (conv && (conv as any).fake) || false
useE... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
if (fake) {
return
}
let timeoutID: ReturnType<typeof setTimeout> | null = null
const handleStart = () => {
if (timeoutID === null) {
let t = timeout
if (typeof t !== 'number') {
t = 1000
}
timeoutID = setTimeout(() => {
timeoutID = null
ctx.client?.conversationOpen... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
if (timeoutID === null) {
let t = timeout
if (typeof t !== 'number') {
t = 1000
}
timeoutID = setTimeout(() => {
timeoutID = null
ctx.client?.conversationOpen({ groupPk: publicKey }).catch((err) => {
console.warn('failed to open conversation,', err)
})
}, t)
... | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
timeoutID = null
ctx.client?.conversationOpen({ groupPk: publicKey }).catch((err) => {
console.warn('failed to open conversation,', err)
})
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(err) => {
console.warn('failed to open conversation,', err)
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
if (timeoutID !== null) {
clearTimeout(timeoutID)
timeoutID = null
}
ctx.client?.conversationClose({ groupPk: publicKey }).catch((err) => {
console.warn('failed to close conversation,', err)
})
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(err) => {
console.warn('failed to close conversation,', err)
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
unsubscribeFocus()
unsubscribeBlur()
handleStop()
} | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
(effect: EffectCallback) => useEffect(effect, []) | wamry/berty | js/packages/store/hooks.ts | TypeScript |
TypeAliasDeclaration |
export type Maybe<T> = T | null | undefined | wamry/berty | js/packages/store/hooks.ts | TypeScript |
TypeAliasDeclaration |
export type SortedConvsFilter = Parameters<
ReturnType<typeof useSortedConvInteractions>['filter']
>[0] | wamry/berty | js/packages/store/hooks.ts | TypeScript |
ArrowFunction |
() => {
let component: SignupSocietyComponent;
let fixture: ComponentFixture<SignupSocietyComponent>;
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [ SignupSocietyComponent ]
})
.compileComponents();
}));
beforeEach(() => {
fixture = TestBed.createComponent(S... | ASMohamedFaheemAnver/SocietyManagementSystem | client/src/app/auth/signup-society/signup-society.component.spec.ts | TypeScript |
ArrowFunction |
() => {
TestBed.configureTestingModule({
declarations: [ SignupSocietyComponent ]
})
.compileComponents();
} | ASMohamedFaheemAnver/SocietyManagementSystem | client/src/app/auth/signup-society/signup-society.component.spec.ts | TypeScript |
ArrowFunction |
() => {
fixture = TestBed.createComponent(SignupSocietyComponent);
component = fixture.componentInstance;
fixture.detectChanges();
} | ASMohamedFaheemAnver/SocietyManagementSystem | client/src/app/auth/signup-society/signup-society.component.spec.ts | TypeScript |
ArrowFunction |
(props: Props) => {
const { type = Cell.Type.DEFAULT, data, cellPadding = Base.Padding.M, className } = props
//create props
const blockWrapperProps = {
className: Classnames(
styles[type ?? Type.DEFAULT],
className
),
}
const toCell = (cell: Cell.Props) => {
const cellProps = {
... | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
ArrowFunction |
(cell: Cell.Props) => {
const cellProps = {
...cell,
padding: cellPadding,
...cell,
};
return (<Cell.Element {...cellProps} />);
} | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
ArrowFunction |
(row: Row.Props) => {
const children = row.cells ? row.cells.map(cell => toCell(cell)) : null;
const rowProps = {
children: children,
...row,
};
return (<Row.Element {...rowProps} />);
} | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
ArrowFunction |
cell => toCell(cell) | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
ArrowFunction |
(rows: Row.Props[]) => {
return rows.map(row => toRow(row));
} | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
ArrowFunction |
row => toRow(row) | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
EnumDeclaration |
enum Type {
DEFAULT = 'table',
} | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
EnumDeclaration |
enum Theme {
DEFAULT = '',
} | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
TypeAliasDeclaration |
type Props = {
type?: Type,
data: {
rows: Row.Props[],
},
cellPadding?: Base.Padding,
className?: string,
} | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
MethodDeclaration |
toTable(data | lthtv8/corona-project | src/components/molecules/table/index.tsx | TypeScript |
ArrowFunction |
() => IngredientTypeSeafood | fuad-ardiono/imin-api | src/modules/ingredient/entities/ingredient-type.entity.ts | TypeScript |
ArrowFunction |
(ingredientTypeSeafood) => ingredientTypeSeafood.ingredientType | fuad-ardiono/imin-api | src/modules/ingredient/entities/ingredient-type.entity.ts | TypeScript |
ClassDeclaration |
@Entity({ name: 'ingredient_type' })
export class IngredientType {
@PrimaryGeneratedColumn()
id: number;
@Column({ name: 'name' })
name: string;
@OneToMany(
() => IngredientTypeSeafood,
(ingredientTypeSeafood) => ingredientTypeSeafood.ingredientType,
)
ingredientTypeSeafood: IngredientTypeSeafo... | fuad-ardiono/imin-api | src/modules/ingredient/entities/ingredient-type.entity.ts | TypeScript |
ClassDeclaration | /**
* Adds existing resource policies to a disk. You can only add one policy
* which will be applied to this disk for scheduling snapshot creation.
*
* > **Note:** This resource does not support zonal disks (`gcp.compute.Disk`). For zonal disks, please refer to the `gcp.compute.DiskResourcePolicyAttachment` resourc... | la3mmchen/pulumi-gcp | sdk/nodejs/compute/regionDiskResourcePolicyAttachment.ts | TypeScript |
InterfaceDeclaration | /**
* Input properties used for looking up and filtering RegionDiskResourcePolicyAttachment resources.
*/
export interface RegionDiskResourcePolicyAttachmentState {
/**
* The name of the regional disk in which the resource policies are attached to.
*/
disk?: pulumi.Input<string>;
/**
* The ... | la3mmchen/pulumi-gcp | sdk/nodejs/compute/regionDiskResourcePolicyAttachment.ts | TypeScript |
InterfaceDeclaration | /**
* The set of arguments for constructing a RegionDiskResourcePolicyAttachment resource.
*/
export interface RegionDiskResourcePolicyAttachmentArgs {
/**
* The name of the regional disk in which the resource policies are attached to.
*/
disk: pulumi.Input<string>;
/**
* The resource polic... | la3mmchen/pulumi-gcp | sdk/nodejs/compute/regionDiskResourcePolicyAttachment.ts | TypeScript |
MethodDeclaration | /**
* Get an existing RegionDiskResourcePolicyAttachment resource's state with the given name, ID, and optional extra
* properties used to qualify the lookup.
*
* @param name The _unique_ name of the resulting resource.
* @param id The _unique_ provider ID of the resource to lookup.
* @par... | la3mmchen/pulumi-gcp | sdk/nodejs/compute/regionDiskResourcePolicyAttachment.ts | TypeScript |
MethodDeclaration | /**
* Returns true if the given object is an instance of RegionDiskResourcePolicyAttachment. This is designed to work even
* when multiple copies of the Pulumi SDK have been loaded into the same process.
*/
public static isInstance(obj: any): obj is RegionDiskResourcePolicyAttachment {
if (obj =... | la3mmchen/pulumi-gcp | sdk/nodejs/compute/regionDiskResourcePolicyAttachment.ts | TypeScript |
FunctionDeclaration |
function ConfirmPass() {
////////CHANGE STATE////////
const [confirmPass, setconfirmPass] = useState({
confirmPassword: ''
})
const handleInputChange = (event) => {
console.log(event.target.value)
setconfirmPass({
...confirmPass,
[event.target.name]: event.target.value
})
}
/... | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
FunctionDeclaration |
function (event) {
togglePasswordVisiblity()
toggleChangeIcon()
} | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
ArrowFunction |
(event) => {
console.log(event.target.value)
setconfirmPass({
...confirmPass,
[event.target.name]: event.target.value
})
} | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
ArrowFunction |
() => {
setPasswordShown(passwordShown ? false : true)
} | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
ArrowFunction |
() => {
setChangeIcon(changeIcon ? false : true)
} | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
ClassDeclaration | ////////////////MERGE FUNCTION IN ONCLICK////////////////
class Pass extends React.Component {
onClick(event) {
togglePasswordVisiblity()
toggleChangeIcon()
}
} | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
MethodDeclaration |
onClick(event) {
togglePasswordVisiblity()
toggleChangeIcon()
} | ninjagabo1312/prueba | src/components/molecules/inputs/input-confirmpass.tsx | TypeScript |
ArrowFunction |
() => ({
businessLoader: new DataLoader(
async keys => Promise.all(
keys.map(key => Business.findOne({_id: key})),
),
{cacheKeyFn: (key: any) => key.toString()},
),
}) | wsoeltz/supportyourlocal | src/server/dataloaders.ts | TypeScript |
ArrowFunction |
async keys => Promise.all(
keys.map(key => Business.findOne({_id: key})),
) | wsoeltz/supportyourlocal | src/server/dataloaders.ts | TypeScript |
ArrowFunction |
key => Business.findOne({_id: key}) | wsoeltz/supportyourlocal | src/server/dataloaders.ts | TypeScript |
ArrowFunction |
(key: any) => key.toString() | wsoeltz/supportyourlocal | src/server/dataloaders.ts | TypeScript |
ArrowFunction |
() => (
<EuiText size="s">
<FormattedMessage
id | AlexanderWert/kibana | x-pack/plugins/security_solution/public/common/components/ml_popover/popover_description.tsx | TypeScript |
ArrowFunction |
(resolve, reject) => {
client.methodCall("UserSummaryRemoteManager2.getGZippedSummary", [userId], (err, data: Uint8Array) => {
/* tslint:disable:no-null-keyword */
if (err) {
Logger.logError("UserSummaryRemoteManager2.getGZippedSummary: return an error: "... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(err, data: Uint8Array) => {
/* tslint:disable:no-null-keyword */
if (err) {
Logger.logError("UserSummaryRemoteManager2.getGZippedSummary: return an error: " + Utils.formatErrorMessage(err));
return reject(err);
} else if (!data) {... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(resolve, reject) => {
client.methodCall("UserSummaryRemoteManager2.getTotalNumberOfEvents", [serializedSubscription], (err, data) => {
if (err) {
Logger.logError("UserSummaryRemoteManager2.getTotalNumberOfEvents: return an error: " + Utils.formatErrorMessage(err));
... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(err, data) => {
if (err) {
Logger.logError("UserSummaryRemoteManager2.getTotalNumberOfEvents: return an error: " + Utils.formatErrorMessage(err));
return reject(err);
} else if (!data) {
Logger.logError("UserSummaryRemoteManag... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(row) => {
changedFiles.push(row.replace(/\\/g, "/"));
} | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(resolve, reject) => {
client.methodCall("VersionControlServer.getSuitableConfigurations", [changedFiles], (err, configurationId) => {
if (err) {
err = err.code === ("ENOENT" || "ENOTFOUND") ? MessageConstants.URL_NOT_REACHABLE : err;
Logger.logError(... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(err, configurationId) => {
if (err) {
err = err.code === ("ENOENT" || "ENOTFOUND") ? MessageConstants.URL_NOT_REACHABLE : err;
Logger.logError("VersionControlServer.getSuitableConfigurations failed with error: " + Utils.formatErrorMessage(err));
... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(resolve, reject) => {
client.methodCall("IDEPluginNotificator.getCurrentTimestamp", [], (err, data) => {
if (err || !data) {
Logger.logError("UserSummaryRemoteManager2.getTotalNumberOfEvents: return an error: " + Utils.formatErrorMessage(err));
retur... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(err, data) => {
if (err || !data) {
Logger.logError("UserSummaryRemoteManager2.getTotalNumberOfEvents: return an error: " + Utils.formatErrorMessage(err));
return reject(err);
}
resolve(data);
} | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(resolve, reject) => {
client.methodCall("IDEPluginNotificator.getBuildMessages", [userId, timestamp.toString()], (err, data) => {
if (err) {
Logger.logError("IDEPluginNotificator.getBuildMessages: return an error: " + Utils.formatErrorMessage(err));
... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(err, data) => {
if (err) {
Logger.logError("IDEPluginNotificator.getBuildMessages: return an error: " + Utils.formatErrorMessage(err));
return reject(err);
}
resolve(data);
} | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(resolve, reject) => {
client.methodCall("RemoteBuildServer2.getRelatedProjects", [suitableConfigurations], (err, buildXmlArray) => {
if (err) {
Logger.logError("RemoteBuildServer2.getRelatedProjects failed with error: " + Utils.formatErrorMessage(err));
... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ArrowFunction |
(err, buildXmlArray) => {
if (err) {
Logger.logError("RemoteBuildServer2.getRelatedProjects failed with error: " + Utils.formatErrorMessage(err));
return reject(err);
} else if (!buildXmlArray) {
Logger.logError("RemoteBuildSer... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
ClassDeclaration |
@injectable()
export class RemoteBuildServer {
private credentialsStore: CredentialsStore;
private remoteLogin: RemoteLogin;
constructor (@inject(TYPES.CredentialsStore) credentialsStore: CredentialsStore,
@inject(TYPES.RemoteLogin) remoteLogin: RemoteLogin) {
this.credentialsSto... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
MethodDeclaration |
private async createAndInitClient(isSilent: boolean = false): Promise<any> {
let credentials: Credentials;
if (isSilent) {
credentials = this.credentialsStore.getCredentialsSilently();
} else {
credentials = await this.credentialsStore.getCredentials();
}
... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
MethodDeclaration |
private async getUserId(): Promise<any> {
const credentials: Credentials = await this.credentialsStore.getCredentials();
if (credentials) {
return credentials.userId;
} else {
throw new Error("User is logged out");
}
} | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
MethodDeclaration |
public async getGZippedSummary(isSilent: boolean = false): Promise<Uint8Array> {
const client: any = await this.createAndInitClient(isSilent);
const userId: string = await this.getUserId();
return new Promise<Uint8Array>((resolve, reject) => {
client.methodCall("UserSummaryRemoteMan... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
MethodDeclaration | /**
* @return - number of event for existing subscriptions.
*/
public async getTotalNumberOfEvents(serializedSubscription: string): Promise<number> {
const client: any = await this.createAndInitClient();
return new Promise<number>((resolve, reject) => {
client.methodCall("UserSumma... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
MethodDeclaration | /**
* @param filesFromPatch - Changed file paths in particular format. The information is required to create request for suitableBuildConfigIds.
* @return - array of all suitable Build Config Ids.
*/
public async getSuitableConfigurations(filesFromPatch: string[]): Promise<string[]> {
const clien... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
MethodDeclaration |
public async getCurrentTimestamp(): Promise<number> {
const client: any = await this.createAndInitClient();
return new Promise<number>((resolve, reject) => {
client.methodCall("IDEPluginNotificator.getCurrentTimestamp", [], (err, data) => {
if (err || !data) {
... | JetBrains/teamcity-vscode-extension | src/dal/remotebuildserver.ts | TypeScript |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.