Example #1
0
// Commit
//------------------------------------------------------------------------------
/*virtual*/ bool FunctionXCodeProject::Commit( const BFFIterator & funcStartIter ) const
{
	NodeGraph & ng = FBuild::Get().GetDependencyGraph();
	AStackString<> name;
	if ( GetNameForNode( funcStartIter, XCodeProjectNode::GetReflectionInfoS(), name ) == false )
	{
		return false;
	}

	if ( ng.FindNode( name ) )
	{
		Error::Error_1100_AlreadyDefined( funcStartIter, this, name );
		return false;
	}

	auto * xcodeProjNode = ng.CreateXCodeProjectNode( name );

	if ( !PopulateProperties( funcStartIter, xcodeProjNode ) )
	{
		return false;
	}

	if ( !xcodeProjNode->Initialize( funcStartIter, this ) )
    {
        return false;
    }

	// handle alias creation
	return ProcessAlias( funcStartIter, xcodeProjNode );
}
Example #2
0
// Commit
//------------------------------------------------------------------------------
/*virtual*/ bool FunctionAlias::Commit( NodeGraph & nodeGraph, const BFFIterator & funcStartIter ) const
{
    if ( nodeGraph.FindNode( m_AliasForFunction ) )
    {
        Error::Error_1100_AlreadyDefined( funcStartIter, this, m_AliasForFunction );
        return false;
    }
    AliasNode * aliasNode = nodeGraph.CreateAliasNode( m_AliasForFunction );

    if ( !PopulateProperties( nodeGraph, funcStartIter, aliasNode ) )
    {
        return false;
    }

    return aliasNode->Initialize( nodeGraph, funcStartIter, this );
}
Example #3
0
// Commit
//------------------------------------------------------------------------------
/*virtual*/ bool FunctionAlias::Commit( const BFFIterator & funcStartIter ) const
{
	NodeGraph & ng = FBuild::Get().GetDependencyGraph();
	if ( ng.FindNode( m_AliasForFunction ) )
	{
		Error::Error_1100_AlreadyDefined( funcStartIter, this, m_AliasForFunction );
		return false;
	}
	AliasNode * aliasNode = ng.CreateAliasNode( m_AliasForFunction );

	if ( !PopulateProperties( funcStartIter, aliasNode ) )
	{
		return false;
	}

	return aliasNode->Initialize( funcStartIter, this );
}
Example #4
0
// Commit
//------------------------------------------------------------------------------
/*virtual*/ bool FunctionSettings::Commit( NodeGraph & nodeGraph, const BFFIterator & funcStartIter ) const
{
    AStackString<> name( "$$Settings$$" );
    if ( nodeGraph.FindNode( name ) )
    {
        Error::Error_1100_AlreadyDefined( funcStartIter, this, name );
        return false;
    }

    SettingsNode * settingsNode = nodeGraph.CreateSettingsNode( name );

    if ( !PopulateProperties( nodeGraph, funcStartIter, settingsNode ) )
    {
        return false;
    }

    return settingsNode->Initialize( nodeGraph, funcStartIter, this );
}