src/utils/NodeConnection.js
File NodeConnection.js
has 322 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/*
* Copyright (c) 2013 - present Adobe Systems Incorporated. All rights reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
Function _receive
has 65 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
NodeConnection.prototype._receive = function (message) {
var responseDeferred = null;
var data = message.data;
var m;
Function connect
has 61 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
NodeConnection.prototype.connect = function (autoReconnect) {
var self = this;
self._autoReconnect = autoReconnect;
var deferred = $.Deferred();
var attemptCount = 0;
Function _refreshInterface
has 51 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
NodeConnection.prototype._refreshInterface = function () {
var deferred = $.Deferred();
var self = this;
var pendingDeferreds = this._pendingInterfaceRefreshDeferreds;
Function registerHandlersAndDomains
has 32 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function registerHandlersAndDomains(ws, port) {
// Called if we succeed at the final setup
function success() {
self._ws.onclose = function () {
if (self._autoReconnect) {
Function refreshInterfaceCallback
has 29 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function refreshInterfaceCallback(spec) {
function makeCommandFunction(domainName, commandSpec) {
return function () {
var deferred = $.Deferred();
var parameters = Array.prototype.slice.call(arguments, 0);