function AdfInitializationBehavior(js) {
  this.Init(js);
}
AdfObject.createSubclass(AdfInitializationBehavior, AdfClientBehavior);
var globalVar = "";
AdfInitializationBehavior.prototype.initialize = function(component) {
  try {
    globalVar = arguments[0];
    var document = window.document;
    var scriptParent = document.body;
    if (scriptParent == null) {
      eval("var component\x3darguments[0]; " + this._js);
      return;
    }
    var scriptElem = document.createElement("script");
    scriptElem.setAttribute("type", "text/javascript");
    var scriptNode = document.querySelector("script[nonce]");
    if (scriptNode) {
      scriptElem.setAttribute("nonce", scriptNode.nonce);
    }
    scriptElem.appendChild(document.createTextNode("var component\x3dwindow['globalVar']; " + this._js));
    scriptParent.appendChild(scriptElem);
    scriptParent.removeChild(scriptElem);
  } catch (e) {
    if (AdfLogger.LOGGER.getLevel() >= AdfLogger.WARNING) {
      AdfLogger.LOGGER.logErrorAsWarning(e, " initializing " + this + " on " + component);
    }
  }
};
AdfInitializationBehavior.prototype.Init = function(js) {
  AdfInitializationBehavior.superclass.Init.call(this);
  AdfAssert.assertString(js);
  this._js = js;
};
