Beispiel #1
0
		protected override CommandCanExecuteResult CanExecute()
		{
			if (!String.Equals(CurrentNode?.Id, Terminals.Identifier))
			{
				return false;
			}

			var semanticModel = (OracleStatementSemanticModel)ExecutionContext.DocumentRepository.ValidationModels[CurrentNode.Statement].SemanticModel;
			_oracleObjectType = (OracleTypeBase)semanticModel.GetTypeReference(CurrentNode)?.SchemaObject.GetTargetSchemaObject();

			return _oracleObjectType != null && _oracleObjectType.FullyQualifiedName != OracleDataType.XmlType.FullyQualifiedName;
		}
Beispiel #2
0
        protected override CommandCanExecuteResult CanExecute()
        {
            if (!String.Equals(CurrentNode?.Id, Terminals.Identifier))
            {
                return(false);
            }

            var semanticModel = (OracleStatementSemanticModel)ExecutionContext.DocumentRepository.ValidationModels[CurrentNode.Statement].SemanticModel;

            _oracleObjectType = (OracleTypeBase)semanticModel.GetTypeReference(CurrentNode)?.SchemaObject.GetTargetSchemaObject();

            return(_oracleObjectType != null && _oracleObjectType.FullyQualifiedName != OracleDataType.XmlType.FullyQualifiedName);
        }
Beispiel #3
0
		public static void Generate(OracleTypeBase type, TextWriter writer)
		{
			writer.WriteLine(UsingClause);

			if (type is OracleTypeObject objectType)
			{
				Generate(objectType, writer);
			}
			else
			{
				Generate((OracleTypeCollection)type, writer);
			}

			writer.WriteLine(CustomTypeBase);
		}
Beispiel #4
0
		public static void Generate(OracleTypeBase type, TextWriter writer)
		{
			writer.WriteLine(UsingClause);

			var objectType = type as OracleTypeObject;
			if (objectType != null)
			{
				Generate(objectType, writer);
			}
			else
			{
				Generate((OracleTypeCollection)type, writer);
			}

			writer.WriteLine(CustomTypeBase);
		}