@Override
	public Parameter moveParameter(int fromOrdinal, int toOrdinal) throws InvalidInputException {
		if (toOrdinal < 0) {
			throw new InvalidInputException("invalid toOrdinal specified: " + toOrdinal);
		}
		manager.lock.acquire();
		try {
			startUpdate();
			checkDeleted();
			if (thunkedFunction != null) {
				return thunkedFunction.moveParameter(fromOrdinal, toOrdinal);
			}
			loadVariables();

			int autoCnt = 0;
			if (autoParams != null) {
				autoCnt = autoParams.size();
				if (fromOrdinal < autoCnt) {
					throw new InvalidInputException("Auto-parameter may not be moved");
				}
				if (toOrdinal < autoCnt) {
					throw new InvalidInputException(
						"Parameter may not be moved before an auto-parameter");
				}
			}

			fromOrdinal -= autoCnt;
			toOrdinal -= autoCnt;

			if (fromOrdinal < 0 || fromOrdinal >= params.size()) {
				return null;
			}
			ParameterDB param = params.get(fromOrdinal);
			if (param.getOrdinal() == toOrdinal) {
				return param;
			}
			params.remove(fromOrdinal);
			if (toOrdinal >= params.size()) {
				params.add(param);
			}
			else {
				params.add(toOrdinal, param);
			}
			updateParametersAndReturn();
			manager.functionChanged(this, PARAMETERS_CHANGED);
			return param;
		}
		finally {
			endUpdate();
			manager.lock.release();
		}
	}
Return the Variable for the given symbol.

@param symbol variable symbol
@return Variable which corresponds to specified symbol
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/function/FunctionDB.java